A targets
workflow for processing animal relocation data for the WEEL.
library(targets)
library(printr) library(data.table)
Note: this workflow only processes files if it finds them at the specified path in metadata. This means you can add a row describing your own input data to metadata()
and use the workflow, without needing all other datasets present on your computer.
tar_read(meta)
All outputs can be directly read with data.table::fread
and the
datetime column will be automatically converted to POSIXct in UTC timezone.
tar_read(exports)
| Column name | Description |
| ----------- | ----------- |
| id | unique animal identifier |
| datetime | date time in UTC |
| doy | day of year, integer. see data.table::yday()
|
| mnth | month, integer. see data.table::month()
|
| yr | year, integer. see data.table::year()
|
| x_long | longitude, EPSG code provided in metadata()
. see R/metadata.R
|
| y_lat | latitude, EPSG code provided in metadata()
. see R/metadata.R
|
| x_proj | projected x coordinate, output EPSG code in metadata()
. see R/metadata.R
|
| y_proj | projected y coordinate, output EPSG code in metadata()
. see R/metadata.R
|
| epsg_proj | output EPSG of 'x_proj' and 'y_proj' as set in metadata()
. |
| [extracols] | Extras specified in metadata()
. Eg. HERD. On output, column names are transformed to snake_case (eg. from 'HERD' to 'herd' or 'COLLAR ID' to 'collar_id')
In target "checkflags", the column named "flag" is a semi-colon separated list of flags indicating why locs are dropped and set to NaN. After target "filters", locs with NaN are dropped.
tar_read(checkflags)[order(name, -N)]
Screening GPS fixes:
https://ropensci.github.io/CoordinateCleaner/articles/Comparison_other_software.html
Effects of habitat on GPS collar performance: using data screening to reduce location error. Lewis et al. 2007
Screening GPS telemetry data for locations having unacceptable error. Laver et al.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.