View source: R/rasterizeGimms.R
| rasterizeGimms | R Documentation | 
Import GIMMS NDVI3g (binary or NetCDF) data into R as Raster* objects.
rasterizeGimms(
  x,
  ext = NULL,
  snap = "out",
  keep = NULL,
  split = FALSE,
  cores = 1L,
  filename = "",
  ...
)
x | 
 
  | 
ext | 
 
  | 
snap | 
 
  | 
keep | 
 
  | 
split | 
 
  | 
cores | 
 
  | 
filename | 
 
  | 
... | 
 Further arguments passed to   | 
If split = TRUE, a list of NDVI3g RasterStack objects
corresponding to the files specified in 'x'; else a single NDVI3g
RasterStack object.
crop, qualityControl,
writeRaster.
## Not run: 
tmp <- tempdir()
## Download NDVI3g.v1 sample data
gimms_files <- downloadGimms(x = as.Date("2000-01-01"),
                             y = as.Date("2000-12-31"),
                             dsn = tmp)
## Extent for clipping
shp <- getData("GADM", country = "DEU", level = 0, path = tmp)
## Rasterize without quality control
gimms_raster <- rasterizeGimms(x = gimms_files,
                               ext = shp) # clipping
plot(gimms_raster[[1]])
lines(shp)
## Rasterize with quality control
gimms_rasterq <- rasterizeGimms(x = gimms_files,
                                ext = shp, # clipping
                                keep = 0)  # quality control
plot(gimms_rasterq[[1]])
lines(shp)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.