Skip to contents
  • TimeVectLayerVariable is a data class that is based on a 3D array. It has two "macro" dimensions: time and spatial. The spatial dimension also holds the geological vector data (points, lines, polygons) that is saved in the Spat_Data. But due to the vertical layer in spatial dimension, the data class actually has three data-dimensions: (time, spat, layer).

  • TimeVectLayerArray is a data class that is based on a 4D array. It has three dimensions: time, spatial, and variable. The spatial dimension also holds the geological vector data (points, lines, polygons) that is saved in the Spat_Data. But due to the vertical layer in spatial dimension, the data class actually has four data-dimensions: (time, spat, layer, variable).

Usage

new_TimeVectLayerVariable(
  data_,
  Name_,
  Unit_,
  Time_,
  Spat_ID,
  Spat_Data,
  na_check = FALSE
)

new_TimeVectLayerArray(
  data_,
  Name_,
  Unit_,
  Time_,
  Spat_ID,
  Spat_Data,
  na_check = FALSE
)

Arguments

data_

(num-array) 3D for TimeVectLayerVariable and 4D for TimeVectLayerArray

Name_, Unit_

(char or vector of char) name and unit of Variable, Unit_ should be converted by units::as_units()

Time_

(vector of lubridate::timepoint) time dimension, created by lubridate::as_date() or lubridate::as_datetime()

Spat_ID

(vector of char) the identifying of the spatial-dimension, they must be contained in the Spat_Data

Spat_Data

(terra::SpatVector) geological data, create by terra::vect()

na_check

(bool) if check the NAs