RE: [R] How to bring an Splus object into R

From: Liaw, Andy <>
Date: Mon 12 Jul 2004 - 06:06:28 EST

>From the `R Data Import/Export' manual, shipped with R, as well as available
from the official R web site (last three paragraphs of Section 3.1, describing functions in the `foreign' package):

Function read.S which can read binary objects produced by S-PLUS 3.x, 4.x or 2000
on (32-bit) Unix or Windows (and can read them on a di erent OS). This is able to read
many but not all S objects: in particular it can read vectors, matrices and data frames and
lists containing those.

Function data.restore reads S-PLUS data dumps (created by data.dump) with the same restrictions (except that dumps from the Alpha platform can also be read).
It should be possible to read data dumps from S-PLUS 5.x and 6.x written with
If you have access to S-PLUS, it is usually more reliable to dump the object(s) in S-PLUS

and source the dumpfile in R. For S-PLUS 5.x and 6.x you may need to use dump(...,
oldStyle=T), and to read in very large objects it may be preferable to use the dumpfile as
a batch script rather than source.

Please learn to read the manual yourself.


> From: Victoria Landsman
> Dear all,
> I like to bring the list created in Splus into R. What is the
> shortest way to do this?
> Much thanks, Vicky.
> [[alternative HTML version deleted]]
> mailing list PLEASE do read the posting guide! Received on Mon Jul 12 06:15:03 2004

This archive was generated by hypermail 2.1.8 : Wed 03 Nov 2004 - 22:54:50 EST