API access

build_auth()

Build token or basic authentication based on given credentials

download_minimal_wastd_turtledata()

Download a minimal dataset of turtle observations from WAStD

download_wastd_sites()

Download Areas of type Site from WAStD

download_wastd_turtledata()

Download all turtle data from WAStD

download_wastd_users()

Download a minimal dataset of turtle observations from WAStD

export_wastd_turtledata()

Export all WAStD turtledata to CSV and GeoJSON files

filter_wastd_turtledata()

Filter WAStD turtledata to an area_name

filter_wastd_turtledata_area()

Filter WAStD turtledata to an area_name

filter_wastd_turtledata_seasons()

Filter WAStD turtledata to a season range

handle_http_status()

Emit a specific warning messages depending on HTTP status

wastd_GET()

Return GeoJSON features from a WAStD API endpoint

wastd_POST()

Send a POST request to WAStD's API

wastd_bulk_post()

Post a list of records to a WAStD or TSC API endpoint

wastd_chunk_post()

POST data to a WAStD API serializer in chunks

wastd_create_update_skip()

Create, update, skip records to a WAStD serializer.

wastd_parse()

Parse a wastd_api_response into a tibble

wastd_post_one()

Post a one record to a WAStD / TSC API endpoint

WA Sea Turtles DB

add_nest_labels()

Add labels for species and nest/track type to parsed turtle-nest-encounters.

disturbance_by_season()

Tally WAStD disturbances by season, cause, and encounter type

filter_alive()

Filter animal encounters to live outcomes: tagging, in water, and rescues

filter_dead()

Filter animal encounters to mortalities: strandings

filter_disturbance()

Filter disturbance data to disturbances

filter_predation()

Filter disturbance data to predator presences

ggplot_disturbance_by_season()

Plot disturbance by season

ggplot_emergence_success()

Plot Emergence Success for excavations of hatched nests

ggplot_hatching_success()

Plot HS for excavations of hatched nests

ggplot_hatchling_misorientation()

Return a ggplot violin plot of hatchling emergence misorientation

ggplot_nesting_success_per_area_season_species()

Return a stacked ggplot barchart of emergences

ggplot_nesting_success_per_area_season_species_pct()

Return a ggplot of nesting success

ggplot_sighting_status_per_area_season_species()

Return a stacked ggplot barchart of processed emergences by recapture status

ggplot_total_emergences_per_area_season_species()

Return a stacked ggplot barchart of emergences by processing status

ggplot_track_success_by_date()

Plot the track success (absolute numbers) of a given species as time series

ggplot_track_successrate_by_date()

Plot the track success rate (relative numbers) of a given species as time series

hatching_emergence_success()

Summarize HS and ES for Nest excavations

hatching_emergence_success_area()

Summarize HS for excavations of hatched nests grouped by area_name

hatching_emergence_success_site()

Summarize HS and ES for excavations of hatched nests grouped by site_name

map_dist()

Map nest and general disturbance observations interactively.

map_fanangles()

Map turtle hatchling emergence orientation from wastd_data

map_mwi()

Map Marine Wildlife Incident 0.6

map_nests()

Map tagged Turtle Nests interactively.

map_tracks()

Map TurtleNestEncounters interactively.

map_wastd()

Map Marine Wildlife Incident 0.6

map_wastd_wamtram_sites()

Map WAStD and WAMTRAM sites

nesting_success_per_area_day_species()

Calculate nesting success for emergences per area, day (turtle_date), species

nesting_success_per_area_season_species()

Calculate nesting success for emergences per area, season, species

nesting_type_by_area_season_age_species()

Pivot table of nesting type by area, season, track age, and species

nesting_type_by_area_season_species()

Pivot table of nesting type by area, season, and species

nesting_type_by_season_age_species()

Pivot table of nesting type by season, track age and species

nesting_type_by_season_calendarday_age_species()

Pivot table of nesting type by season, calendardate, and track age, and species

nesting_type_by_season_calendarday_species()

Pivot table of nesting type by season, calendardate, and species

nesting_type_by_season_day_species()

Pivot table of nesting type by season, turtle date. and species

nesting_type_by_season_species()

Pivot table of nesting type by season and species

nesting_type_by_season_week_age_species()

Pivot table of nesting type by season, season_week, iso_week, track age, and species

nesting_type_by_season_week_site_species()

Pivot table of nesting type by season, season_week, iso_week, and species

nesting_type_by_season_week_species()

Pivot table of nesting type by season, season_week, iso_week, and species

nesting_type_by_site_season_age_species()

Pivot table of nesting type by site, season, track age, and species

nesting_type_by_site_season_species()

Pivot table of nesting type by site, season, and species

parse_animal_encounters()

Parse a wastd_api_response of animal-encounters to tbl_df

parse_area()

Parse a wastd_api_response of area to tbl_df

parse_area_sf()

Parse a wastd_api_response of area to tbl_df and sf

parse_encounterobservations()

Parse a wastd_api_response of Encounter observations to tbl_df

parse_surveys()

Parse a wastd_api_response of surveys to tbl_df

parse_turtle_nest_encounters()

Parse a wastd_api_response of turtle-nest-encounters to tbl_df

print(<wastd_api_response>)

S3 print method for 'wastd_api_response'.

sighting_status_per_area_season_species()

Calculate sighting status for emergences per area, season, species

sighting_status_per_site_season_species()

Calculate sighting status for emergences per site, season, species

summarise_hatching_and_emergence_success()

[Stable]

summarise_wastd_data_per_day_site()

Summarise WAStD data per day and site

total_emergences_per_area_season_species()

Calculate processing success for emergences per area, season, species

total_emergences_per_site_season_species()

Calculate processing success for emergences per site, season, species

track_success()

Calculate nesting success as number of tracks with nests vs other tracks

track_success_by_species()

The nesting success grouped by season and species

tracks_ts()

Plot of nesting_type_by_season_day_species over time

WA Sea Turtles DB - Surveys

duplicate_surveys()

List sites with more than one production survey on a given date

list_survey_count()

Create a table of survey counts from the output of parse_surveys

list_survey_effort()

Create a table from the surveyed hours from the output of parse_surveys

plot_survey_count()

Plot the surveyed hours from the output of parse_surveys

plot_survey_effort()

Plot the surveyed hours from the output of parse_surveys

survey_count()

Return the number of surveys for a given site_id and season

survey_count_heatmap()

Plot the survey count from the output of parse_surveys as heatmap

survey_ground_covered()

Return the number of surveys for a given site_id and season

survey_hours_heatmap()

Plot the surveyed hours from the output of parse_surveys as heatmap

survey_hours_per_person()

Sum the hours surveyed per person by season from the output of parse_surveys

survey_hours_per_site_name_and_date()

Sum the hours surveyed per site_name and turtle date from the output of parse_surveys

survey_season_site_stats()

Generate a season by site summary from the output of parse_surveys

survey_season_stats()

Generate a season summary from the output of parse_surveys

survey_show_detail()

Select main survey attributes

surveys_per_site_name_and_date()

Count number of surveys per season, turtle date and site_name from the output of parse_surveys

ODK Central Turtle Data

add_hatching_emergence_success_odkc()

Add calculated egg count, hatching and emergence success to odkc_data$tracks_egg.

add_nest_labels_odkc()

Add labels for species and nest/track type to parsed turtle-nest-encounters from ODK Central.

download_odkc_turtledata_2020()

Download all turtle data from DBCA's ODK Central 2020

exclude_training_species_odkc()

Exclude ODKC records with species "corolla-corolla".

filter_odkc_turtledata()

Filter odkc_data to a given area_name.

general_disturbance_by_season_odkc()

Tally ODKC General disturbances by season, cause, and encounter type

hatching_emergence_success_odkc()

Summarize HS and ES for Nest excavations

map_dist_odkc()

Map Disturbance observations interactively from ODK Central data.

map_mwi_odkc()

Map Marine Wildlife Incident 0.6 parsed with ruODK from ODK Central.

map_sv_odkc()

Map Site Visit Start and End from ODK Central data over WAStD Sites.

map_tracks_odkc()

Map tracks directly from ODK data

map_tt_odkc()

Map Turtle Tagging 3.0 parsed with ruODK from ODK Central.

nest_disturbance_by_season_odkc()

Tally ODKC Nest disturbances by season, cause, and encounter type

nesting_type_by_area_season_age_species_odkc()

Pivot table of nesting type by area, season, track age, and species for ODKC data

nesting_type_by_area_season_species_odkc()

Pivot table of nesting type by area, season, and species for ODKC data

nesting_type_by_season_age_species_odkc()

Pivot table of nesting type by season, track age and species for ODKC data

nesting_type_by_season_calendarday_age_species_odkc()

Pivot table of nesting type by season, calendardate, and track age, and species for ODKC data

nesting_type_by_season_calendarday_species_odkc()

Pivot table of nesting type by season, calendardate, and species for ODKC data

nesting_type_by_season_day_species_odkc()

Pivot table of nesting type by season, turtle date. and species for ODKC data

nesting_type_by_season_species_odkc()

Pivot table of nesting type by season and species for ODKC data

nesting_type_by_season_week_age_species_odkc()

Pivot table of nesting type by season, season_week, iso_week, track age, and species for ODKC data

nesting_type_by_season_week_site_species_odkc()

Pivot table of nesting type by season, season_week, iso_week, and species for ODKC data

nesting_type_by_season_week_species_odkc()

Pivot table of nesting type by season, season_week, iso_week, and species for ODKC data

nesting_type_by_site_season_age_species_odkc()

Pivot table of nesting type by site, season, track age, and species for ODKC data

nesting_type_by_site_season_species_odkc()

Pivot table of nesting type by site, season, and species for ODKC data

Turtle Nesting Census import

Turtle Tagging DB import

download_w2_data()

Download Turtle Tagging data from WAMTRAM2.

map_wamtram()

Map WAMTRAM data

w2_online()

Test whether the Turtle Tagging Database WAMTRAM2 is accessible and online

WACensus access

Helpers

absolute_angle()

Return the smallest possible angle between two compass bearings

add_dates()

Add turtle dates to a dataframe with datetime col observation_start_time.

datetime_as_isoweek()

Calculate the isoweek from a given datetime

datetime_as_season()

Calculate the "turtle season" (FY) from a given datetime

datetime_as_seasonweek()

Calculate the isoweek from a given datetime

datetime_as_turtle_date()

Calculate the "turtle date" from a given datetime

exclude_training_species() filter_realspecies()

Exclude records with species "corolla-corolla".

exclude_training_surveys() filter_realsurveys()

Exclude training surveys.

extract_possibly()

Wrap magrittr::extract to return field value or -1

fdate_as_tdate()

Days since fiscal year start as true date

filter_missing_site() filter_nosite()

Filter records with missing site_id

filter_missing_survey() filter_nosurvey()

Filter records with missing survey_id

filter_surveys_missing_end()

Filter surveys with a missing end_source_id.

filter_surveys_requiring_qa()

Filter surveys with "NEEDS QA" in start_comments or end_comments.

filter_wastd_season()

Filter a dataframe of tracks, disturbance, incidents, or surveys to season

get_more()

Decide whether the given download limit has been reached

gj_linestring_to_st_linestring()

Convert a GeoJSON linestring into an st_linestring

httpdate_as_gmt08()

Return a UTC HTTP date string as POSIXct object in GMT+08

httpdate_as_gmt08_turtle_date()

Calculate the "turtle date" from a given datetime

httpdate_as_season()

Calculate the "turtle season" (FY) from a given UTC HTTP datestring

humanize()

Convert between url-safe dash-separated-strings and Human Readable Title Case

join_tsc_sites()

Join a dataframe with lat/lon to sf objects of sites and areas.

leaflet_basemap()

Create a Leaflet basemap for Western Australia

map_chr_hack()

Map given function, handle null as NA and flatten_chr()

mean_bearing()

Calculate the mean bearing of two bearings (from, to)

mis_bearing()

Return the smallest possible angle for a sector's mean bearing and a given direction

odkc_works()

Check whether ODKC is online

read_table()

Read a table from a SQL connection using either RODBC or DBI

sentencecase()

Convert between url-safe dash-separated-strings and Human readable sentence case

sf_as_tbl()

Convert a SimpleFeatures object to a non-spatial dataframe

tdate_as_fdate()

True date as days since fiscal year start

tracks_as_geojson()

Convert tracks to a GeoJSON string

tun()

A wrapper for tidyr::unnest_wider

urlize()

Convert between url-safe dash-separated-names and Human Readable Title Case

verify_odkc_turtledata()

Abort if the parameter x is not of class wastd_data

verify_wamtram_data()

Abort if the parameter x is not of class wastd_data

verify_wastd_data()

Abort if the parameter x is not of class wastd_data

wastd_works()

Check whether API token is set and WAStD is online

wastdr_msg_abort()

rlang::abort() with a red error message with a cross symbol.

wastdr_msg_info()

Print a blue info message with an info symbol if verbose.

wastdr_msg_noop()

Print a green noop message with a filled circle symbol if verbose.

wastdr_msg_success()

Print a green success message with a tick symbol if verbose.

wastdr_msg_warn()

rlang::warn() with a yellow warning message with a warning symbol if verbose.

wastdr_settings() get_wastd_url() get_wastdr_api_url() get_wastdr_api_token() get_wastdr_api_un() get_wastdr_api_pw() get_wastdr_verbose()

Get or set wastdr WAStD settings

wastdr_setup()

Configure default WAStD settings

Example data

odkc_data

Turtle Nesting Census data from ODK Central.

print(<odkc_turtledata>)

S3 print method for 'odkc_turtledata'.

print(<wamtram_data>)

S3 print method for 'wamtram_data'.

print(<wastd_data>)

S3 print method for 'wastd_data'.

tsc_data

TSC data, parsed, first ten records each

wastd_ae

WAStD AnimalEncounters, parsed, test data captured by author

wastd_ae_raw

WAStD AnimalEncounters, unparsed, test data captured by author

wastd_area_raw

WAStD Areas, unparsed

wastd_data

Turtle Nesting Census data from WAStD

wastd_surveys_raw

WAStD Surveys, unparsed, test data captured by author

wastd_tne

WAStD TurtleNestEncounters, parsed, test data captured by author

wastd_tne_raw

WAStD TurtleNestEncounters, unparsed, test data captured by author