Skip to content
Prev 11642 / 29559 Next

raster or rgdal: problem with geometry of tif + tifw file

Hi Agus,

The problem is that you raster is rotated (GeoTransform[3] and [5] are not zero)

GeoTransform =
 445548.7745816645, -0.109570548549058, 0.216912817625298
 4628418.279379116, 0.216912817625298, 0.109570548549058

raster ignored the rotation. I have fixed that (in version 1-8-19) by
throwing an error for such a file.

readGDAL will read the file, but as points (SpatialPointsDataFrame),
which you could interpolate to a non-rotated raster. I do not plan to
support such files in raster, but I might include a function for
memory-safe transformation to a non-rotated file.

Thanks for catching & reporting this,

Robert
On Sun, May 8, 2011 at 9:50 AM, Agustin Lobo <alobolistas at gmail.com> wrote: