dataset_process is used to load individual studies using the config file generated from dataset_configure(). dataset_configure and dataset_process are applied to every study in the remake.yml file.

dataset_process(
  filename_data_raw,
  config_for_dataset,
  schema,
  resource_metadata,
  unit_conversion_functions,
  filter_missing_values = TRUE
)

Arguments

filename_data_raw

Raw data.csv file for any given study

config_for_dataset

Config settings generated from dataset_configure()

schema

Schema for traits.build

resource_metadata

Metadata about the traits compilation read in from the config folder. Its optional trait_value_term_order (alphabetical, the default, or input_order) sets whether the terms of a multi-term trait value are sorted or keep the source's order; see util_trait_value_term_order(). Its optional additional_traits_table_fields adds the database's own columns to the traits table, each set by a dataset like measurement_remarks; see util_additional_traits_table_fields().

unit_conversion_functions

unit_conversion.csv file read in from the config folder

filter_missing_values

Default filters missing values from the excluded data table; change to false to see the rows with missing values

Value

List, AusTraits database object

Examples

if (FALSE) { # \dontrun{
dataset_process("data/Falster_2003/data.csv", dataset_configure("data/Falster_2003/metadata.yml",
read_yaml("config/traits.yml")),
get_schema(),
get_schema("config/metadata.yml", "metadata"),
get_unit_conversions("config/unit_conversions.csv"))
} # }