move.aeqd_crs
An azimuthal equidistant projection centred on the tracks (move2's mt_aeqd_crs): distances and directions from the centre are true in it, a local metric projection for tracks anywhere; and the tracks in it. The centre: the centroid of the locations (on the sphere for longitude / latitude), the middle of their longitude and latitude ranges (center), or [longitude, latitude]. move2 takes the centroid to EPSG:4236 (Hu Tzu Shan) where WGS84 is meant, about a kilometre off; here it stays in WGS84, as landschaft's.
| Input | Type | What it is |
tracksrequired | vector | the tracks |
| Output | Type | What it is |
crs | text | the projection, a PROJ string (for vector.reproject's crs) |
tracks | vector | the tracks in it |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
center | any | centroid (default), center or [longitude, latitude] |
units | text | m (default) or km |
move.as_tracks
Tracks from points or a table of locations (move2's mt_as_move2, landschaft's as_tracks): ordered by track and time (stable), the tracks in the order they first appear, as every move node needs. The time is a column of datetimes as text (ISO 8601, UTC) or of numbers; the track one of names or numbers. A table's x and y columns become points in the coordinate system given.
| Input | Type | What it is |
vector | vector | points, one per location |
table | table | or a table with a column of x and one of y |
| Output | Type | What it is |
tracks | vector | the locations, ordered |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
x | text | a table's column of the x or longitude (x) |
y | text | a table's column of the y or latitude (y) |
crs | text | a table's coordinate system: EPSG:4326, a WKT... |
sort | bool | order by track and time (true) |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.azimuth
The direction of each step, clockwise from north (move2's mt_azimuth): the geodesic azimuth on the coordinate system's ellipsoid in longitude / latitude (lwgeom's st_geod_azimuth, GeographicLib, the same numbers), in (-pi, pi]; the direction on the grid, atan2(dx, dy), in a projected system or without one. NaN at the last location of each track and where a location repeats the previous.
| Input | Type | What it is |
tracksrequired | vector | the tracks: points ordered by track and time |
| Output | Type | What it is |
tracks | vector | the tracks with the column |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
units | text | rad (default) or deg |
column | text | the column given (azimuth) |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.distance
The distance from each location to the next of its track (move2's mt_distance, the same numbers): on the sphere of S2 (radius 6 371 010 m, as sf::st_distance with s2) in longitude / latitude, the straight line in the coordinate system's units otherwise. NaN at the last location of each track.
| Input | Type | What it is |
tracksrequired | vector | the tracks: points ordered by track and time |
| Output | Type | What it is |
tracks | vector | the tracks with the column |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
units | text | m (the default in longitude / latitude) or km; none keeps metres or the CRS's units |
column | text | the column given (distance) |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.distribution
A distribution of step lengths or turn angles (amt's make_distribution): gamma (shape, and scale or rate), exp (rate), lnorm (meanlog, sdlog), hnorm (sd) for step lengths; vonmises (kappa, mu 0) or unif (min, max) for turn angles. The parameters not given take amt's defaults (gamma 1, 1; exp 1; lnorm 0, 1; hnorm 1; unif -pi, pi; von Mises 1, 0).
| Output | Type | What it is |
distribution | step_distribution | the distribution |
table | table | its parameters |
| Setting | Type | What it is |
namerequired | text | gamma, exp, lnorm, hnorm, vonmises or unif |
shape | number | the parameter shape (of the distributions that have it) |
scale | number | the parameter scale (of the distributions that have it) |
rate | number | the parameter rate (of the distributions that have it) |
meanlog | number | the parameter meanlog (of the distributions that have it) |
sdlog | number | the parameter sdlog (of the distributions that have it) |
sd | number | the parameter sd (of the distributions that have it) |
min | number | the parameter min (of the distributions that have it) |
max | number | the parameter max (of the distributions that have it) |
kappa | number | the parameter kappa (of the distributions that have it) |
mu | number | the parameter mu (of the distributions that have it) |
move.filter_min_n_burst
The bursts (move.resample) of at least min_n locations (amt's filter_min_n_burst).
| Input | Type | What it is |
tracksrequired | vector | the tracks in bursts |
| Output | Type | What it is |
tracks | vector | the bursts kept |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
min_n | integer | the least locations of a burst (3) |
track | text | the column of the track (default: the usual names) |
move.filter_movebank_visible
The tracks without the locations Movebank hides (move2's mt_filter_movebank_visible): those of the column visible when there is one; otherwise the records not marked as outliers (manually, by an algorithm or on import), and those marked valid by hand.
| Input | Type | What it is |
tracksrequired | vector | the tracks (move.read_tracks) |
| Output | Type | What it is |
tracks | vector | the locations Movebank shows |
table | table | their attributes that are numbers |
move.filter_per_interval
One location per time interval of each track (move2's mt_filter_per_interval): the intervals of lubridate's floor_date, multiples counted from the start of the next larger unit (minutes within the hour, hours within the day, days within the month), weeks from Sunday; the first, the last or one at random (R's sample.int after set.seed(seed), move2's picks). The times must be datetimes.
| Input | Type | What it is |
tracksrequired | vector | the tracks |
| Output | Type | What it is |
tracks | vector | a location per interval |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
unit | text | the interval: hour (default), 15 mins, 2 hours, day, week, month, year... |
criterion | text | first (default), last or random |
seed | integer | random: the seed of R's generator (1) |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.filter_unique
The tracks without duplicated times within a track (move2's mt_filter_unique and mt_unique). criterion subsets (default): of the records of a track with the same time, those that only repeat another or hold less (each value equal to the other's or missing) are dropped, with a warning when some remain; subsets_equal the same with numbers equal within R's all.equal (1.5e-8); first, last: the first or last record of each time; sample: one at random (R's sample.int after set.seed(seed), move2's picks).
| Input | Type | What it is |
tracksrequired | vector | the tracks |
| Output | Type | What it is |
tracks | vector | the records kept |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
criterion | text | subsets (default), subsets_equal, first, last or sample |
columns_also | any | more columns whose values must also match for records to be duplicates (a list) |
seed | integer | sample: the seed of R's generator (1) |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.fit_distribution
A distribution fitted to step lengths or turn angles (amt's fit_distr, the same numbers): gamma by maximum likelihood with R's Nelder-Mead from the closed-form estimates (fitdistrplus' fitdist; steps of length 0 take the smallest other length); exp the maximum likelihood rate 1 / mean(x) (amt fits it by BFGS, which fails for rates under 0.001); lnorm by Nelder-Mead; hnorm sqrt(mean(x^2)); unif the smallest and largest value; vonmises kappa by maximum likelihood (circular's mle.vonmises), mu 0. The missing values are left out.
| Input | Type | What it is |
valuesrequired | any | the steps (move.steps) or a table |
| Output | Type | What it is |
distribution | step_distribution | the distribution fitted |
table | table | its parameters |
| Setting | Type | What it is |
namerequired | text | gamma, exp, lnorm, hnorm, vonmises or unif |
column | text | the column of the values (sl_ for gamma, exp, lnorm and hnorm; ta_ for vonmises and unif) |
move.interpolate
Locations at given times between the recorded ones (move2's mt_interpolate). Without times, the records without a location (empty points) get one between the locations before and after them. With times (a list, or a unit such as 1 hour or 15 mins for a regular sequence from the first to the last time), a record is added for each time within the span of each track that the track does not have, and located. A location is placed on the great circle between its neighbours in proportion to the time (in longitude / latitude, and through it in a projected system, as move2 does with s2), on the straight line without a coordinate system. Gaps longer than max_time_lag are left empty. Ordered by track and time.
| Input | Type | What it is |
tracksrequired | vector | the tracks |
| Output | Type | What it is |
tracks | vector | the tracks with the locations interpolated |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
times | any | the times: a list (datetimes as text, or numbers), or a unit (1 hour, 15 mins, day...) |
max_time_lag | number | gaps longer than this (seconds) left empty |
omit | bool | keep only the records at the times (false) |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.nsd
The net squared displacement: the squared distance of each location from the first of its track (amt's nsd), in the units of the coordinates (squared degrees in longitude / latitude, as amt).
| Input | Type | What it is |
tracksrequired | vector | the tracks |
| Output | Type | What it is |
tracks | vector | the tracks with the column |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
column | text | the column given (nsd) |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.random_numbers
Draws of a distribution of steps (amt's random_numbers), from R's generator after set.seed(seed): amt's numbers. Turn angles of a von Mises distribution are wrapped to (-pi, pi].
| Input | Type | What it is |
distributionrequired | step_distribution | the distribution |
| Output | Type | What it is |
table | table | the draws (value) |
| Setting | Type | What it is |
n | integer | how many (100) |
seed | integer | the seed of R's generator (1) |
move.random_steps
Each observed step with n_control random steps from its start (amt's random_steps, the same steps): the data of a step selection function. For each step but the first of a track (or of a burst), the observed step (case_ 1) and n_control steps from the same start (case_ 0) whose lengths and turn angles are drawn from sl_distr and ta_distr (default: a gamma and a von Mises distribution fitted to each track's steps), turned from the direction of the previous step; step_id_ names the stratum. As amt, n_draws numbers are drawn from each distribution once per track and each random step takes one of them at random. Bursts of fewer than 3 steps are left out. R's generator after set.seed(seed), the tracks in turn. The steps must be in a projected coordinate system (move.aeqd_crs).
| Input | Type | What it is |
stepsrequired | vector | the steps (move.steps), projected |
sl_distr | step_distribution | the distribution of the step lengths |
ta_distr | step_distribution | the distribution of the turn angles |
| Output | Type | What it is |
steps | vector | the observed and random steps (case_, step_id_) |
table | table | their attributes that are numbers |
distributions | vector | the distributions of each track (sl_distr, ta_distr and their parameters), without geometries |
| Setting | Type | What it is |
n_control | integer | random steps per observed step (10) |
n_draws | integer | numbers drawn from each distribution per track (100000) |
seed | integer | the seed of R's generator (1) |
track | text | the column of the track (default: the usual names) |
move.read_tracks
Animal tracks from a Movebank file (move2's mt_read, landschaft's load_tracks): the CSV files Movebank exports (also .csv.gz) and the zip files of Env-DATA (the CSV inside), as points in EPSG:4326, one per record. The time is timestamp (UTC), the track the individual (individual-local-identifier; when an individual carried several tags, the individual and the tag, in a new individual-tag-local-identifier column, as move2 does); the outlier flags are numbers 1 and 0. Records without coordinates (other sensors) keep an empty location. Ordered by track and time (stable), as every move node needs.
| Output | Type | What it is |
tracks | vector | the locations: points with the file's columns |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
pathrequired | text | the file (.csv, .csv.gz, .zip), relative to the model's folder |
sort | bool | order by track and time (true; move2 keeps the file's order) |
move.resample
Locations at a regular rate, in bursts (amt's track_resample, the same locations and bursts): from the location start of each track, the next location kept is the first at least rate - tolerance later, in the same burst when it is at most rate + tolerance later, else it starts a new burst; the locations in between are dropped. Each location kept gets its burst (1, 2... within its track) in the column burst_, which move.steps and move.random_steps follow.
| Input | Type | What it is |
tracksrequired | vector | the tracks |
| Output | Type | What it is |
tracks | vector | the locations kept, with burst_ |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
raterequired | any | the rate: seconds, or a text such as 2h or 15min |
tolerancerequired | any | the tolerance: seconds, or a text such as 15min |
start | integer | the location (0-based, in each track) to start at (0) |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.segments
The step from each location to the next of its track as a line (move2's mt_segments): one feature per location with its attributes, a two-point line per step and the location itself (a point) at the last location of each track.
| Input | Type | What it is |
tracksrequired | vector | the tracks |
| Output | Type | What it is |
segments | vector | a line per step |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.simulate_brownian
Tracks of Brownian motion (move2's mt_sim_brownian_motion): each step moves by normal draws of standard deviation sqrt(sigma^2 dt) along x and along y, from the start. R's generator after set.seed(seed): the same tracks as move2 (the tracks one after the other, x before y). Columns time and track, points without a coordinate system.
| Output | Type | What it is |
tracks | vector | the locations |
table | table | time and track of each |
| Setting | Type | What it is |
t | any | the times (numbers; default 1 to 10): one list for every track, or a list of one per track |
sigma | any | the diffusion: a number or one per step, for every track, or a list of one per track (1) |
tracks | any | how many tracks (ids 1, 2...) or their ids (2) |
start | any | the first location [x, y], or a list of one per track ([0, 0]) |
seed | integer | the seed of R's generator (1) |
move.speed
The speed of each step: the distance over the time lag (move2's mt_speed). Locations of a track must not share their time (move.filter_unique drops them). NaN at the last location of each track.
| Input | Type | What it is |
tracksrequired | vector | the tracks: points ordered by track and time |
| Output | Type | What it is |
tracks | vector | the tracks with the column |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
units | text | m/s, km/h, m/h or km/d (default: metres, or the CRS's units, per second) |
column | text | the column given (speed) |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.steps
The steps between consecutive locations of each track (amt's steps and steps_by_burst, the same numbers), of each burst when the tracks have move.resample's burst_: a line per step, with its track, burst_, start and end (x1_, x2_, y1_, y2_), length sl_, direction direction_p (anticlockwise from east, in (-pi, pi]), turn angle ta_ from the previous step (NaN at the first step of each track or burst and after a step of length 0), the times t1_, t2_ and dt_ (seconds). In longitude / latitude the lengths are great-circle distances in metres (sf::st_distance) and the directions geodesic bearings turned into angles from east: amt reads the bearing, clockwise from north, as if it were that angle; here it is converted, pi / 2 - bearing.
| Input | Type | What it is |
tracksrequired | vector | the tracks |
| Output | Type | What it is |
steps | vector | a line per step |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
lonlat | bool | lengths and directions on the sphere (default: when the coordinate system is geographic) |
keep_cols | text | the tracks' other columns kept: start (of the location a step starts at), end, both (suffixes _start and _end) or none |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.time_lags
The time from each location to the next of its track (move2's mt_time_lags), exact between datetimes (differences of nanoseconds). NaN at the last location of each track.
| Input | Type | What it is |
tracksrequired | vector | the tracks: points ordered by track and time |
| Output | Type | What it is |
tracks | vector | the tracks with the column |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
units | text | s (default), min, h or d |
column | text | the column given (time_lag) |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.time_of_day
Day or night at each location, or at the end or start of each step (amt's time_of_day): sunrise and sunset of the location's date (UTC) as suncalc computes them (the sun's upper edge at -0.833 degrees), and with include_crepuscule dawn and dusk (the sun at -6 degrees, civil twilight). A column of day, night (and dawn, dusk); empty where the sun does not rise or set that day. suncalc takes the noon of the machine's time zone; here, the noon of UTC.
| Input | Type | What it is |
tracksrequired | vector | tracks (with a coordinate system) or their steps |
| Output | Type | What it is |
tracks | vector | the tracks or steps with the column |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
include_crepuscule | bool | also dawn and dusk (false) |
where | text | steps: at their end (default) or start |
column | text | the column given (tod) |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.track_data
One row per track (in the order they appear) with the columns whose value does not change within a track (move2's mt_track_data): the animal's, the tag's, the study's... as features without a geometry.
| Input | Type | What it is |
tracksrequired | vector | the tracks |
| Output | Type | What it is |
tracks | vector | a feature per track, without a geometry |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.track_lines
Each track as a line through its locations in time order (move2's mt_track_lines): one feature per track, its id, the number of locations (n_locations) and the columns whose value does not change within a track (move.track_data's). Empty locations are left out; a track with a single location gets no line (an empty geometry).
| Input | Type | What it is |
tracksrequired | vector | the tracks |
| Output | Type | What it is |
lines | vector | a line per track |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.track_summary
amt's summaries of each track, a line per track (move.track_lines's, with n_locations and the track's data): cum_dist (the sum of its steps, metres in longitude / latitude), tot_dist (from the first to the last location), straightness (tot_dist / cum_dist), msd (the mean squared distance of the locations from their centre), sinuosity (Benhamou 2004, the turn angles in radians: amt takes them as degrees; NaN under two steps) and tac (the turn angle correlation, Dray et al. 2010).
| Input | Type | What it is |
tracksrequired | vector | the tracks |
| Output | Type | What it is |
tracks | vector | a line per track with its summaries |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |
move.turn_angle
The change of direction at each location, in [-pi, pi) (move2's mt_turnangle): the azimuth of the step leaving it minus that of the step arriving, positive to the right. NaN at the first and last location of each track.
| Input | Type | What it is |
tracksrequired | vector | the tracks: points ordered by track and time |
| Output | Type | What it is |
tracks | vector | the tracks with the column |
table | table | their attributes that are numbers |
| Setting | Type | What it is |
units | text | rad (default) or deg |
column | text | the column given (turn_angle) |
time | text | the column of the time (default: timestamp, time, datetime, date_time or t) |
track | text | the column of the track (default: individual-tag-local-identifier, individual-local-identifier, track, track_id, id, individual or animal) |