Skip to content

Commit

Permalink
Updates for austraits 3.0 (#21)
Browse files Browse the repository at this point in the history
Update austraits package vignette & AusTraits tutorial vignette to match austraits version 3.0 release.
  • Loading branch information
ehwenk authored Dec 8, 2024
1 parent 7507982 commit 3086f5a
Show file tree
Hide file tree
Showing 7 changed files with 622 additions and 314 deletions.
680 changes: 451 additions & 229 deletions AusTraits_tutorial.qmd

Large diffs are not rendered by default.

236 changes: 158 additions & 78 deletions austraits_package.qmd

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion data/extra_functions.R
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ austraits_weighted_means <- function(austraits, traits) {

# any data that is a mean, median or raw, create a site mean
data_means <-
(austraits %>% austraits::join_locations())$traits %>%
(austraits %>% austraits::join_location_coordinates())$traits %>%
dplyr::filter(trait_name %in% traits) %>%
dplyr::filter(value_type %in% c("mean", "raw", "median")) %>%
dplyr::mutate(
Expand Down
10 changes: 5 additions & 5 deletions database_structure.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ print_schema_element <- function(elements) {
writeLines()
elements$elements %>%
util_list_to_df1() %>%
austraits::convert_list_to_df1() %>%
my_kable_styling() %>%
writeLines()
}
Expand Down Expand Up @@ -112,7 +112,7 @@ In detail:

```{r entity_type}
schema$entity_type$values %>%
util_list_to_df1() %>%
austraits::convert_list_to_df1() %>%
my_kable_styling() %>%
writeLines()
```
Expand Down Expand Up @@ -158,7 +158,7 @@ Possible values are:

```{r basis_of_record}
schema$basis_of_record$values %>%
util_list_to_df1() %>%
austraits::convert_list_to_df1() %>%
my_kable_styling() %>%
writeLines()
```
Expand All @@ -177,7 +177,7 @@ Possible value types are:

```{r value_type}
schema$value_type$values %>%
util_list_to_df1() %>%
austraits::convert_list_to_df1() %>%
my_kable_styling() %>%
writeLines()
```
Expand All @@ -188,7 +188,7 @@ Possible values are:

```{r basis_of_value}
schema$basis_of_value$values %>%
util_list_to_df1() %>%
austraits::convert_list_to_df1() %>%
my_kable_styling() %>%
writeLines()
```
Expand Down
3 changes: 3 additions & 0 deletions dictionary.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

A core component of the traits.build database structure is a trait dictionary that clearly defines and describes each trait concept included within the trait database.

A description of the trait dictionary is available at: Wenk, E.H., Sauquet, H., Gallagher, R.V., Brownlee, R., Boettiger, C., Coleman, D., Yang, S., Auld, T., Barrett, R., Brodribb, T., Choat, B., Dun, L., Ellsworth, D., Gosper, C., Guja, L., Jordan, G.J., Le Breton, T., Leigh, A., Lu-Irving, P., Medlyn, B., Nolan, R., Ooi, M., Sommerville, K.D., Vesk, P., White, M., Wright, I.J., Falster, D.S., 2024. The AusTraits plant dictionary. Sci Data 11, 537. [DOI: 10.1038/s41597-024-03368-z](https://doi.org/10.1038/s41597-024-03368-z).


Building upon the standard outlined by the ETS [Ecological Trait-data Standard](https://doi.org/10.1111/2041-210X.13288), all numeric traits must have standard units and an allowable range. Categorical traits must have a list of allowable trait values.

Each trait concept must have a complete, explicit definition to eliminate confusion between trait concepts.
Expand Down
2 changes: 1 addition & 1 deletion file_structure_data_metadata.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ This section provides `r tolower(schema$metadata$elements$contributors$descripti

```{r, echo=FALSE, results="show"}
schema$metadata$elements$contributors$elements$data_collectors$elements %>%
util_list_to_df1() %>%
austraits::convert_list_to_df1() %>%
my_kable_styling()
```

Expand Down
3 changes: 3 additions & 0 deletions index.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ Imagine you wanted to build a database of traits. You might start by compiling d

`traits.build` is a data standard, R package, and workflow that is desgined to help you build a harmonised, relational database from disparate datasets. The package was first developed to create [`austraits.build`](https://github.com/traitecoevo/austraits.build/) an, open-source database of Australian plant traits. The code has been transformed into a standalone package allowing anyone to build a relational, tabular database for any taxonomic group and any collection of traits.

A description of this package is available at: Wenk, E., Bal, P., Coleman, D., Gallagher, R., Yang, S., Falster, D., 2024. Traits.build: A data model, workflow and R package for building harmonised ecological trait databases. Ecological Informatics 83, 102773. [DOI: j.ecoinf.2024.102773](https://doi.org/10.1016/j.ecoinf.2024.102773)


## About this manual

This manual is a step-by-step user guide to the `traits.build` standard, R package and workflow manual. Alongside this manual, you may find the following resources useful:
Expand Down

0 comments on commit 3086f5a

Please sign in to comment.