From m@@nnell @ending from tibco@com  Wed Nov  7 23:35:54 2018
From: m@@nnell @ending from tibco@com (Michael Sannella)
Date: Wed, 7 Nov 2018 14:35:54 -0800
Subject: [Rd] error unserializing ascii format (v2 or v3)
Message-ID: <CAHPe-e-QwCV7Q3O4nqtFt0VfSDQbsx8BoSekG8FsigE7-vnqbw@mail.gmail.com>

I ran into an interesting error unserializing a file created with
ascii=TRUE:

R 3.5.1 (Windows or Linux):
    > unserialize(serialize(list(raw=as.raw(c(39,41))), NULL, version=2,
ascii=TRUE))
    Error in unserialize(serialize(list(raw = as.raw(c(39, 41))), NULL,
version = 2,  :
      ReadItem: unknown type 29, perhaps written by later version of R

The same error happens when the serialization is done with version=2
or version=3.  It does not happen if the serialization is done with
ascii=FALSE.

Note that 0x29 == 41.  It looks like unserialize is reading the wrong
line.

I tried this in earlier versions of R on Windows, and the same error
happens in every version from R-2.15.3 (the earliest I have) on up.

  ~~ Michael Sannella

	[[alternative HTML version deleted]]



[Rd] error unserializing ascii format (v2 or v3)
Michael Sannella