[R] problem with save function

2008-08-18 Thread Juan Manuel Barreneche
Hello list! i write because i'm having a strange problem with the save function, here an example: x - stats::runif(20) y - list(a = 1, b = TRUE, c = oops) save(x, y, file = xy.Rdata) xy - load(xy.Rdata) xy [1] x y why does this happens, when: x [1] 0.96586833 0.60340508 0.23465887

Re: [R] problem with save function

2008-08-18 Thread Rolf Turner
Read the help for load(); note the ``Value'' section. cheers, Rolf Turner On 19/08/2008, at 11:51 AM, Juan Manuel Barreneche wrote: Hello list! i write because i'm having a strange problem with the save function, here an example: x - stats::runif(20) y - list(a =

Re: [R] problem with save function

2008-08-18 Thread Henrik Bengtsson
...and see saveObject() and loadObject() in R.utils, which might do what you expected, e.g. x - stats::runif(20) y - list(a=1, b=TRUE, c=oops) saveObject(list(foo=x,bar=y), xy.Rdata) xy - loadObject(xy.Rdata) str(xy) List of 2 $ foo: num [1:20] 0.1154 0.6534 0.0876 0.5977 0.6841 ... $

Re: [R] problem with save function

2008-08-18 Thread Juan Manuel Barreneche
well i see i've been really foolish, sorry thank you! Juan On Mon, Aug 18, 2008 at 9:09 PM, Henrik Bengtsson [EMAIL PROTECTED]wrote: ...and see saveObject() and loadObject() in R.utils, which might do what you expected, e.g. x - stats::runif(20) y - list(a=1, b=TRUE, c=oops)