[R-sig-Geo] converting old sp objects
dgoliche at sclc.ecosur.mx
Fri Oct 27 18:49:06 CEST 2006
Thanks. No problem, I use GRASS and was converting them using rgrass6. I
just hoped there was an even simpler way. I had missed the posting on
the change, but realised more or less what was going on a few days ago
when I upgraded.
Roger Bivand wrote:
>On Fri, 27 Oct 2006, Duncan Golicher wrote:
>>I have quite a number of SpatialGridDataFrame objects that were saved
>>internally under R 2.3.0 and sp0.8-16. Can anyone suggest a quick and
>>easy way to convert them for use with R2.4.0 and sp0.9-2. (I do have
>>ways, but they are all a bit longwinded).
>The issue was announced on this list on 28 September:
>and has been on the Rgeo site since about the same time.
>The major issue is that the way new-style classes (and objects belonging
>to those classes) are defined internally, so the internal (*.RData)
>representations are not compatible.
>To transfer from the old internal form, use R < 2.4.0, and sp < 0.9 to for
>example export column by column to GRASS, and then read back in in R >=
>2.4.0 and sp >= 0.9. Alternatively for non-GRASS users, rgdal and the
>GTiff fotmat could be used (and should work with multiple bands). The
>writeAsciiGrid() function in maptools could also be used. There is no way
>of upgrading the serialised object from the *.RData form directly.
>We know that this is an unfortunate incompatibility, but the changes in
>the methods package are being made to improve class/object handling,
>making the software faster and more robust, so the difficulties are
>unavoidable. For critical projects already using R < 2.4.0, I suggest only
>upgrading when sensible.
Dr Duncan Golicher
Ecologia y Sistematica Terrestre
Conservación de la Biodiversidad
El Colegio de la Frontera Sur
San Cristobal de Las Casas,
Email: dgoliche at sclc.ecosur.mx
Tel: 967 674 9000 ext 1310
Fax: 967 678 2322
United Kingdom Skypein; 020 7870 6251
Skype name: duncangolicher
More information about the R-sig-Geo