[R-sig-Geo] Getting the other GIS to recognize files created by writeRaster()

Howard Butler hobu.inc at gmail.com
Fri Oct 14 18:11:08 CEST 2011


On Oct 13, 2011, at 12:57 PM, Dylan Beaudette wrote:

> I can't believe that I am asking for advice on how to assist my
> special-needs GIS software with recognizing files created by the
> raster/rgdal packages.
> 
> Recently (after some silent update by IT no doubt), I noticed that
> files created like this:
> 
> writeRaster(r.mast,  filename='spatial_data/latest/mast-model',
> datatype='FLT4S', format='ENVI', overwrite=TRUE, NAflag=-999)
> 
> ... aren't read-in properly by ArcGIS (9.3.1). Specifically, the
> raster statistics and the NODATA value aren't read from the file or
> from the .xml file that is automatically generated by GDAL. I have
> tried all of the different formats supported by the raster package,
> with the 'ENVI' format getting the closest to working (statistics
> almost correct but missing NODATA information). Are there any
> additional things I can do to help ArcGIS figure these files out
> without any tweaking from within the hulking beast? Ideally, I would
> like to update model estimates on a semi-regular basis and have the
> files ready for viewing by colleagues-- without manual intervention.

Dylan,

I think you want the ESRI_XML_PAM creation option set to YES using the GTiff driver.

Howard


More information about the R-sig-Geo mailing list