FieldToArray: Convert a Field to Arrays

View source: R/export-methods.R

FieldToArrayR Documentation

Convert a Field to Arrays

Description

Convert a Field (or the data.table from a Field) into a list of multi-deminsional arrays (indexed Lon, Lat and Time), with one array in the list per Layer in the input Field.

Usage

FieldToArray(
  x,
  start.date = NULL,
  calendar = "365_day",
  add.missing.cols = TRUE,
  add.missing.rows = TRUE,
  global.extent = FALSE,
  cname = FALSE,
  invertlat = FALSE,
  verbose = FALSE
)

Arguments

x

the data.table of a Field

add.missing.cols

logical, if TRUE fill empty longitude columns (should be regularly spaced or you'll get silliness), default is TRUE

add.missing.rows

logical, if TRUE fill empty latitude rows (should be regularly spaced or you'll get silliness), default is TRUE

global.extent

logical, if TRUE extend the array to be the entire global extent, default is FALSE

cname

the column name to convert, if not set a list is returned

invertlat

start in the north

verbose

print some information

Value

an array or a list or arrays

Author(s)

Joerg Steinkamp joerg.steinkamp@senckenberg.de, Matthew Forrest matthew.forrest@senckenberg.de


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