An internal function that checks that the data.table has the required columns. Used within most, if not all, other atlastools functions.
atl_check_data(data, names_expected = c("x", "y", "time"))
data | The tracking data to check for required columns. Must be in the form of a data.frame or similar, which can be handled by the function colnames. |
---|---|
names_expected | The names expected as a character vector.
By default, checks for the column names |
None. Breaks if the data does not have required columns.
Pratik R. Gupte
# basic (and only) use if (FALSE) { atl_check_data( data = data, names_expected = c("x", "y", "time") ) }