crop-methods: Crop methods

crop-methodsR Documentation

Crop methods

Description

Methods for cropping DGVMTools objects (and data.tables) to each other, to raster and sp objects (and basically anything that can be coerced in a raster::Extent object). The data.table in the "data" slot of the DGVMTools object (or the stand-alone data.table), must have columns named "Lon" and "Lat" otherwise these methods fail. Unpleasantly.

Usage

## S4 method for signature 'Field'
crop(x, y, spatial.extent.id = NULL, ...)

## S4 method for signature 'Comparison'
crop(x, y, spatial.extent.id = NULL, ...)

## S4 method for signature 'data.table'
crop(x, y, spatial.extent.id = NULL, ...)

Arguments

x

A Field or Comparison or a stand-alone data.table to be cropped

y

Anything from which raster::Extent object can be derived

spatial.extent.id

A character string to describe the spatial extent (y) required for meta-data consistency. Must be provided when cropping Field or Comparison objects

...

Other arguments, not currently used

Value

A spatially cropped object

Author(s)

Matthew Forrest matthew.forrest@senckenberg.de


MagicForrest/DGVMTools documentation built on Aug. 23, 2024, 8:05 a.m.