Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

subsample

Subsample a Trajectory


Description

This function subsamples a regular trajectory (i.e. changes the time lag between successive relocations).

Usage

subsample(ltraj, dt, nlo = 1,
          units = c("sec", "min", "hour", "day"), ...)

Arguments

ltraj

an object of class ltraj

dt

numeric value. The new time lag (should be a multiple of the time lag in ltraj)

nlo

an integer, or a vector of integers (with length equal to the number of bursts in ltraj), indicating the position of the first location of the new bursts in the old bursts. For example, if the previous time lag is equal to 300 seconds and the new time lag is 900 seconds, the new bursts may begin at the first, second or third relocations of the old bursts in ltraj.

units

character string. The time units of dt

...

additional arguments to be passed to other functions

Value

An object of class ltraj

Author(s)

Clement Calenge clement.calenge@ofb.gouv.fr

See Also

ltraj for additional information on objects of class ltraj, is.regular for regular trajectories.

Examples

data(capreotf)
plot(capreotf)

toto <- subsample(capreotf, dt = 900)
plot(toto)

adehabitatLT

Analysis of Animal Movements

v0.3.25
GPL (>= 2)
Authors
Clement Calenge, contributions from Stephane Dray and Manuela Royer
Initial release
2020-01-11

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.