stephenb wrote:
any ideas? has anybody tried to recover RData files before?

I have seen messages about that problem here before (see RSiteSearch(".RData corrupted") for a sampling), but I don't think I've seen any really satisfactory solutions. It would be nice to have an error tolerant .RData dumper: it would load and display objects until it hit an error, then report on the error, and perhaps partial information on the object it was loading. With something like that you'd know if you had successfully recovered the .RData file, and if not, would have some hints about what was missing.

The source for the regular loader is in https://svn.r-project.org/R/trunk/src/main/serialize.c, and this could be a start for the dumper.

Duncan Murdoch



Duncan Murdoch-2 wrote:
On 7/13/2009 3:38 PM, sten...@go.com wrote:
   Is there a way to identify the beginning and end of an .RData file?
   I am trying to restore lost files on opensolaris where the table of
contents
   is overwritten and will be reading the raw disk byte by byte.
   I looked at several files in hex and the end seems different, while
most of
   them, but not all begin with RDX2.X
No, there is nothing special written at the end of a file. Many .RData files are compressed (by internal gzip), so the RDX2 header is hidden, and you'll see bytes 1F 8B instead. (I don't think we write the trailer bytes on the gzip stream, but I'm not sure about that.)

Duncan Murdoch

______________________________________________
R-help@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.





______________________________________________
R-help@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.

Reply via email to