[R] Problem with RGui and MASS

Angelo Canty canty at math.mcmaster.ca
Sun Aug 1 21:02:47 CEST 2004


Using R1.9.1 for Windows with Windows 2000 (also XP), I have come
across the following problem that I have not seen before and am at
a loss to explain.  If I create an object using rlm from library(MASS)
and then save the workspace, I cannot reopen it using RGUI by double 
clicking on the .RData file as I normally do.  If I double click on
the icon, R starts and then gives the following message in a pop-up 

Fatal error: Unable to restore saved data in .RData

On the R console there is the further message

Error: object 'family' not found whilst loading namespace 'MASS'

This does not occur when I use RTerm to start R 1.9.1 nor does it
happen with RGui 1.8.1.  Even more puzzling (at least to me) is that
if I open RGui 1.9.1 and use load to load the workspace then it
works fine.  This is a bit of a pain however as I have a lot of
.RData files in different directories and double clicking on them
opens RGui with the appropriate working directory.

Has anyone observed this before or know what the problem might be?
Is it something that I did wrong (on two computers)? 

Here is a very simple example of the code I have used.

rm(list=ls(all=T)) # start with a blank slate
x <- 1:10
y <- rnorm(10, 1+2*x)
model.rlm1 <- rlm(y~x)

Thanks for your help,

|   Angelo J. Canty                Email: cantya at mcmaster.ca     |
|   Mathematics and Statistics     Phone: (905) 525-9140 x 27079 |
|   McMaster University            Fax  : (905) 522-0935         |
|   1280 Main St. W.                                             |
|   Hamilton ON L8S 4K1                                          |

More information about the R-help mailing list