Skip to content
/ tscr Public

Threatened Species and Communities (tsc.dbca.wa.gov.au/) Data Export and Analysis

License

Unknown, MIT licenses found

Licenses found

Unknown
LICENSE
MIT
LICENSE.md
Notifications You must be signed in to change notification settings

dbca-wa/tscr

Repository files navigation

tscr: An R client for the Threatened Species and Communities DB (TSC) tscr logo

CI Test coverage Last-changedate GitHub issues

The goal of tscr is to provide read/write access to TSC data, and to provide working examples of analysis and visualisation of TSC data to answer QA, ecological, and management questions as well as working data ETL pipelines.

For conservation managers and ecologists

Here we’ll list working examples of conservation management nature, ecological, or data QA questions answered with TSC data.

Example questions (to be replaced with working examples):

  • How many birds rose in conservation listing status in WA in the past X years?
  • Which conservation significant plants have been recorded in DBCA District X?
  • What is the predicted habitat for a taxon known under taxonomic name X?
  • Generate a formatted PDF and a plain CSV spreadsheet of threatened flora and fauna names in WA.
  • Generate an interactive map of all accepted occurrences in area X.
  • List conservation documents coming up for review within the next 6 months.
  • List occurrences flagged for review.

Help us complete this list by filing new “Data export or analysis requests” here.

For data engineers

If you wish to run any of the included working examples or create new data analyses, install this package and configure tscr to TSC’s API with your own credentials as outlined below.

Use cases:

  • Update TSC taxonomy from WACensus: vignette("wacensus", package="tscr"))
  • Create a bulk data export into spreadsheet or GIS formats.
  • Build your own analyses and reports to answer conservation management, ecological, or QA questions.
  • ETL of bulk data from third parties (data returns from consultants) into TSC.

Install tscr:

# install.packages("devtools")
remotes::install_github("dbca-wa/tscr", 
                        dependencies = TRUE, 
                        upgrade = "ask",
                        build_vignettes = TRUE)

Set up tscr, run usethis::edit_r_environ(), add your TSC API Token, then restart your R session.

TSC_API_TOKEN="Token xxx"

Read vignette("setup", package="tscr")) to learn more about the configuration of tscr.

Working examples for data access and analyses are available as package vignettes (browseVignettes("tscr")), and as articles here.

For contributors

Found a bug in tscr, need a new tscr feature, or need a working example to generate a data product from TSC? Let us know here!

Want to chat about TSC? Join the “TSC” group on DBCA’s Teams! (You’ll need a DBCA account to access this group.)

Want to contribute code? Start with the contribution guide, but don’t be afraid to ask for help and submit early PRs.

For package maintainers

Tasks that can be run for each release are shown below.

usethis::use_version(which = "dev") # patch, dev, minor, major

# Rebuild included package data, used for tests and vignettes
source(here::here("data-raw/make_data.R"))

# Tests shall pass
devtools::test()

styler::style_pkg()
lintr:::addin_lint_package() # some lint errors are OK
devtools::document(roclets = c("rd", "collate", "namespace", "vignette"))
spelling::spell_check_package()
spelling::spell_check_files("README.Rmd", lang = "en_AU")
spelling::update_wordlist()
codemetar::write_codemeta()
if (fs::file_info("README.md")$modification_time <
  fs::file_info("README.Rmd")$modification_time) {
  rmarkdown::render("README.Rmd", encoding = "UTF-8", clean = TRUE)
  if (fs::file_exists("README.html")) fs::file_delete("README.html")
}
#
# Checks
goodpractice::goodpractice(quiet = FALSE)
devtools::check(cran = FALSE, remote = TRUE, incoming = TRUE)
#
# Add new feature to news if user-facing
usethis::edit_file("NEWS.md")

# Commit and push

About

Threatened Species and Communities (tsc.dbca.wa.gov.au/) Data Export and Analysis

Topics

Resources

License

Unknown, MIT licenses found

Licenses found

Unknown
LICENSE
MIT
LICENSE.md

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages