[R] Get user system name

Duncan Murdoch murdoch at stats.uwo.ca
Tue Mar 17 00:36:19 CET 2009


On 16/03/2009 6:09 PM, Sundar Dorai-Raj wrote:
> Assuming "USER" is defined on your system then
> 
> Sys.getenv("USER")
> 
> ought to work.

In Windows you need to look at

Sys.getenv("USERNAME")

instead.

Duncan Murdoch




More information about the R-help mailing list