[R] VERY TINY question: missing function to clear the console?

Hans-Joerg Bibiko bibiko at eva.mpg.de
Thu Jul 13 15:54:43 CEST 2006


Hi,

many thanks for the hints!

>>
>> Hi,
>>
>> for presentation purposes I would like to clear to whole console
>> window (like in a UNIX terminal: 'clear').
>>
>> Is there such a function?
>>
>> If not, I could image that is not too hard to write such a function.
>
> At the risk of this being a stupid answer: An easy way would be
>
>     system("clear");
>
> This should work under unixes that provide the "clear" command,  
> don't know
> about windows.
>

OK. That works fine on a Mac running R in X11. But I'm using the nice  
R Mac GUI.


> If there is no "clear screen" function in R (I haven't seriously  
> looked
> for one), I think one of the reasons for that might be that writing  
> that
> in a multi-platform portable way is actually a somewhat more laborious
> thing to do than it seems.

My question is very specific to R Mac GUI, so I will post my tiny  
question to that developer mailing list.

All the best,

Hans



More information about the R-help mailing list