[R] .Rhistory in R.app

Rob Goedman robjgoedman at me.com
Wed Dec 9 20:57:17 CET 2009


Maria,

Try changing the name of .Rhistory in the Startup preferences to something like .Rosxhistory. Press enter to make sure the change is accepted and try again.
The problem is that R itself overwrites the file .Rhistory if it is told to save the workspace.

Rob



On Dec 9, 2009, at 10:33 AM, Maria Gouskova wrote:

> Dear R users,
> 
> I am having a minor but annoying issue with R.app. It doesn't retain
> the history information from the previous sessions. By "history," I
> mean a record of commands/functions entered into R rather than the
> list of objects--that is properly recorded in the .Rdata file as well
> as in a workspace file I save separately.
> 
> System details:
> 
> R version 2.9.0
> R.app GUI 1.28
> Mac OS 10.6.2 (MacBook, Intel 2.4 GHz, 4 Gb RAM)
> 
> Things I've done:
> 
> R>Preferences>Startup>History: Read history file on startup is
> checked; R history file directory is specified with a path to my
> preferred directory (~/Documents/...). I've tried it with the default
> setting, too--it makes no difference.
> 
> I've checked the permissions on the .Rhistory file. The default
> .Rhistory file created by R has the permissions set at -rw-r--r--.
> 
> I've moved the .Rhistory file to a different location (Desktop), so
> that R would create a new one. Makes no difference--command history is
> still empty at startup.
> 
> R has kept track of history on my system in the past--the file I moved
> to the desktop has a record of my work from about a year ago. (By the
> way, that file's permissions are -rwx-----.) Judging by what is in the
> old .Rhistory file, the problem started around the time of my upgrade
> from 2.7.x to 2.8. I am reluctant to upgrade to R 2.10 in the middle
> of a project, because every R upgrade I've done in the past has broken
> something, and I've had nothing but grief with my open source apps
> after upgrading to Snow Leopard. So if there is some kind of a fix
> that doesn't involve upgrading R, I'd love to hear about it.
> 
> Maria Gouskova
> 
> ______________________________________________
> 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