standard_error, standard_deviation.bind_databases <-- build_combineconvert_df_to_list <-- util_df_to_listconvert_list_to_df1 <-- util_list_to_df1convert_list_to_df2 <-- util_list_to_df2plot_trait_distribution_beeswarm, trait_pivot_longer and trait_pivot_wider had been in both austraits and traits.build packages and have now been removed from traits.buildflatten_database (had been suggested to be database_create_combined_table)dataset_testdataset_test function, so it is checked explicitly by traits.build (run on Example datasets)As described in #134, fixes some minor issues with
dataset_testThis is the first major release of the {traits.build} package, providing a workflow to harmonise trait data from diverse sources. The code was originally built to support AusTraits (see Falster et al 2021, doi:10.1038/s41597-021-01006-6, https://github.com/traitecoevo/austraits.build) and has been generalised here to support construction of other trait databases. Detailed instructions are available at
traits.build at develop commit c2be7f9 (version 2.1.0.900). Nothing is changed but the package's own identity: its name, version, authorship, and the system.file() lookups and schema filename that follow from it. Databases built with responses.build are identical to those built with traits.build apart from the engine version stamp and build_info$session_info.austraits depends on both: built databases still carry the S3 class traits.build, and still carry https://github.com/traitecoevo/traits.build as the isCompiledBy related identifier. Both are pinned by tests. See PLAN.md.Everything below is inherited history from traits.build, retained for provenance.
dataset_test() no longer aborts with the condition has length > 1 for a dataset that declares more than one identifier. metadata$identifiers is a list, so is.na() on it returns one value per identifier.observation_id, location_id and the context ids were generated by sorting with sort() and as.factor(), which collate according to the session's LC_COLLATE. The same dataset therefore produced different ids on a contributor's machine than on CI, which runs in the C locale (#29). Ids are now always generated using C-locale collation, matching what previous builds produced on CI, so existing outputs are unchanged. util_separate_and_sort() is likewise no longer locale-dependent.process_format_identifiers() no longer fails with object 'schema' not found. Its third argument is the schema, as documented, rather than the trait data, and it now reads the identifiers list it is passed instead of looking one level too deep. dataset_test() was erroring on every dataset that declares identifiers.metadata_add_contexts() no longer writes time-valued contexts as a number of seconds (9:00:00 became 32400.0) when called with user_responses, and now reports when a time column has been reformatted so the recorded values can be recognised as matching data.csv (#49).metadata_add_contexts(), metadata_add_traits() and metadata_add_identifiers() now guess column types from the same number of rows as the build (guess_max = 100000), so a sparse column can no longer be typed one way when metadata is written and another way when the database is built.metadata_add_source_doi() now reports clearly that the optional rcrossref package is needed, and offers to install it in interactive sessions, instead of failing with there is no package called 'rcrossref' (#178).autraits.build in DESCRIPTION, the package documentation and NEWS.md, and pointed at a URL that did not resolve. The Code of Conduct and reference website links in README.md were also dead or redirecting, and now resolve directly.CITATION.cff and inst/CITATION, so citation("traits.build") and GitHub's "Cite this repository" widget both return the Wenk et al. (2024) paper. CITATION.cff is excluded from the package tarball via .Rbuildignore.README.md, which had been added twice.