flatten_data | R Documentation |
Flatten a dataset
flatten_data(data)
data |
(list) The dataset object returned by |
The "flat" format refers to the fully joined source L0 dataset in "wide" form with the exception of the core observation variables, which are in "long" form (i.e. using the variable_name, value, unit columns of the observation table). This "flat" format is the "widest" an L1 ecocomDP dataset can be consistently spread due to the frequent occurrence of L0 source datasets with > 1 core observation variable.
(tbl_df, tbl, data.frame) A single flat table created by joining and spreading all tables
, except the observation table. See details for more information on this "flat" format.
Warnings/Errors from flatten_data()
can most often be fixed by addressing any validation issues reported by read_data()
(e.g. non-unique composite keys).
Ancillary identifiers are dropped from the returned object.
# Flatten a dataset object
flat <- flatten_data(ants_L1)
flat
# Flatten a list of tables
tables <- ants_L1$tables
flat <- flatten_data(tables)
flat
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.