Re: [R-sig-Geo] Issues with a GDB file in R?

2018-05-02 Thread Cotton Rockwood
Hi Roman - As far as I know, 'readOGR' does not read tables in file geodatabases. (see https://gis.stackexchange.com/questions/184013/read-a-table-from-an-esri-file-geodatabase-gdb-using-r). I'm guessing this is the problem you are running into with R. In addition to Sean's suggestions, you

Re: [R-sig-Geo] Substitute raster stack values based on matrix index

2018-04-10 Thread Cotton Rockwood
Hi Thiago - Here is an approach using 'mapply' and 'reclassify'. I changed your example raster stack so the values range from 1:100 rather than 1:ncell(r) since that is what you stated in your problem: # Create raster stack r <- raster(ncol=50, nrow=50) s <- stack(lapply(1:10, function(x)