[R] How do I reload sessions from a non-default directory in OS X?

David Winsemius dwinsemius at comcast.net
Wed Dec 24 04:02:44 CET 2008


On Dec 23, 2008, at 5:18 PM, Bill McNeill (UW) wrote:

> i use the GUI version of R on OS X.  I launch it by double-clicking  
> on the R
> icon.  The process always starts in my home directory which means  
> that the
> only .RData file that is ever read in is the one in my home  
> directory.  I
> would instead like to have different R sessions saved in different
> directories, but I can't figure out how to do this.
>
> A workaround is to use the shell version of R and always change to the
> directory containing my saved session before launching, but I prefer  
> to use
> the GUI version.
>
> Is there a command to tell R to load a session from a particular  
> location?
> How do other people with Macs do this?

?load

(It's not Mac-specific.)

If you want to clean out the workspace you could use:

rm( ls() )

You can also associate file types with your R.app.

-- 
David Winsemius
>
>
> -- 
> Bill McNeill
> http://staff.washington.edu/billmcn/index.shtml
>
> 	[[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at r-project.org 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.



More information about the R-help mailing list