setKeyDGVM: Sets keys on data.table based in the spatial (Lon, Lat) and...

View source: R/small-utility-functions.R

setKeyDGVMR Documentation

Sets keys on data.table based in the spatial (Lon, Lat) and temporal (Year, Month, Day), present.

Description

Keys should be set on all data.table object for sorts, joins, DGVMTool-defined operators etc. This function should be called on a data.table stored in a Field after it has been created, including if it was created by averaging another data.table because it seems as keys are not conserved.

Usage

setKeyDGVM(dt)

Arguments

dt

The data.table for which to set the key

Value

Returns nothing because changes the original data.table by reference (this is the data.table way)

Author(s)

Matthew Forrest matthew.forrest@senckenberg.de


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