This class represents geotrellis raster data objects in R. Note that only expert users should attempt to manipulate data using these methods directly. Instead, most users should use the methods provided in the package.

Fields

  • $idcharacter name of object in Scala interpreter.
  • $crsCRS coordinate reference system.
  • $extentExtent extent of spatial data.
  • $resnumeric cell resolution (width and height).
  • $nrowinteger number of rows.
  • $ncolinteger number of rows.
  • $ncellinteger number of cells.
  • $no_data_typenumeric value used to represent missing data.
  • $data_typecharacter description of data type.

Usage

r <- gt_RasterLayer$new()

r$print()

r$read_data(path) r$read_metadata() r$write_data(path) r$delete_data() r$values() r$compare(y)

r$project.to.crs(crs, res, method) r$project.to.raster(y, method) r$resample(y, method) r$mask(y, maskvalue) r$crop(extent) r$cellStats(stat) r$zonal(y, stat)

Arguments

crs
CRS coordinate reference system object.
maskvalue
numeric value in y to mask out values.
method
character name of method to use for resampling/reprojection.
path
character file path for GeoTIFF raster.
stat
character name of statistic to calculate.
res
numeric resolution for new data.
y
gt_RasterLayer object.

Details

$new() create a new raster layer object. $finalize() destroy the object.

$print() print the object.

$read_data(path) read spatial data to asosciate with the object. $read_metdata() load spatial metadata. $write_data() write data to asosciate with the object. $delete_data() delete the data associated with the object.

$values() values in data associated with the object. $compare(y) compare the spatial properties of the object with another object.

$project_to_crs(crs, res, method) project data to new coordinate system. $project_to_raster(y, method) project data to new coordinate system using another object as a template. $resample(y, method) resample a data to match the spatial properties of another object. $mask(y, maskvalue) mask data by another object. $crop(extent) crop data to a specified extent. $cellStats(stat) calculate a statistic based on the data. $zonal(y, stat) calculate summary statistics for each zone.

See also

gt_RasterLayer-methods.