vmaxlp: Maximum one-way linear speed of a loop trip

View source: R/vmaxlp.R

vmaxlpR Documentation

Maximum one-way linear speed of a loop trip

Description

Function to estimate the maximum one-way linear speed of a loop trip.

Usage

vmaxlp(sdata, qi = 4, nloc = 5, method = "ML", prob = 0.99, ...)

Arguments

sdata

A data frame containing columns with the following headers: "id", "DateTime", "lat", "lon", "qi". See the data turtle for an example. The function filters the input data by a unique "id" (e.g. transmitter number, identifier for each animal). "DateTime" is the GMT date & time of each location in class POSIXct or character with the following format "2012-06-03 01:33:46". "lat" and "lon" are the recorded latitude and longitude in decimal degrees. "qi" is the quality index associated with each location fix. The input values can be either the number of GPS satellites or Argos Location Classes. Argos Location Classes will be converted to numerical values, where "A", "B", "Z" will be replaced with "-1", "-2", "-3" respectively. The greater number indicates a higher accuracy.

qi

An integer specifying the minimum quality index associated with a location used for the estimation. Default is 4 (e.g. 4 GPS satellite or more).

nloc

An integer specifying the minimum number of successive locations to be considered a loop trip.

method

Available options are "sample" (i.e. sample quantile - see quantile) and "ML" (maximum likelihood estimation - see details). Default is "ML".

prob

A value (0 to 1) specifying the sample quantile or cumulative probability for one-way linear speed of a loop trip. Values beyond this threshold are considered 'outliers' and excluded from estimation of maximum one-way linear speed of a loop trip. Default is 0.99. See details.

...

Extra arguments passed to dupfilter.

Details

The function first detects a "loop trip". Loop trip behaviour is represented by spatial departure and return involving more than 3 consecutive locations (Shimada et al. 2012). The function calculates the net (i.e. straight-line) distance between the departure and turning point as well as the turning point and return location of a loop trip. It then calculates the one-way travelling speed to or from each turning point for each loop trip. To exclude implausible outliers, the function discards extreme values based on the specified quantile or an estimated probability distribution for the loop trip speed, depending on the selected method. If the "ML" method is selected, a Gamma distribution is assumed and the shape and scale parameters are estimated via maximum likelihood estimation using the optim function. The maximum value within a given quantile or probability range (e.g. 0.99) represents the maximum one-way linear speed at which an animal would travel during a loop trip.

Value

Maximum one-way linear speed of a loop trip (vmaxlp) estimated from the input data. The unit km/h.

Note

The input data must not contain temporal or spatial duplicates. A minimum of 8 locations are required.

Author(s)

Takahiro Shimada

References

Shimada T, Jones R, Limpus C, Hamann M (2012) Improving data retention and home range estimates by data-driven screening. Marine Ecology Progress Series 457:171-180 \Sexpr[results=rd]{tools:::Rd_expr_doi("10.3354/meps09747")}

See Also

ddfilter, ddfilter_loop, track_param, dupfilter


TakahiroShimada/SDLfilter documentation built on Nov. 15, 2023, 10:01 p.m.