Re: [R] clear console

From: Bos, Roger <roger.bos_at_us.rothschild.com>
Date: Thu 05 Apr 2007 - 11:58:59 GMT

This has been asked previously and I happened to have saved the final answer:

cls <- function() {

       require(rcom)
       wsh <- comCreateObject("Wscript.Shell")
       comInvoke(wsh, "SendKeys", "\014")
       invisible(wsh)

}  

-----Original Message-----
From: r-help-bounces@stat.math.ethz.ch
[mailto:r-help-bounces@stat.math.ethz.ch] On Behalf Of Gabor Grothendieck
Sent: Thursday, April 05, 2007 7:39 AM
To: Robert McFadden
Cc: r-help@stat.math.ethz.ch
Subject: Re: [R] clear console

Check out:

http://tolstoy.newcastle.edu.au/R/help/06/02/21634.html

On 4/5/07, Robert McFadden <robert-mcfadden@o2.pl> wrote:
> Hi R Users,
>
> In Windows I can clear console using CTRL-L, but can I do this by
> certain command in my programs? e.g
>
> for (i in 1:100000){
>
> something
>
> clear console
>
> }
>
>
>
> Best,
>
> Rob
>
>
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help@stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide
http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Thu Apr 05 22:03:28 2007

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Thu 05 Apr 2007 - 12:30:47 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.