Skip to content
Prev 8977 / 29559 Next

drop layer/band from SpatialGridDataFrame

Andy - how about these two options

monthly.sp at data <- monthly.sp at data[-1,]

or (cheating with the help of raster package)

monthly.stack <- as(monthly.sp, 'RasterStack')
monthly.stack <- dropLayer(monthly.stack, 1)
monthly.sp <- as(monthly.stack, 'SpatialGridDataFrame')

Apologies if these are nonsense - I don't have time to actually test 
these out on a toy example at the moment.

Matt
On 8/10/2010 3:02 PM, Andy Bunn wrote: