loop: Looping over all individuals

View source: R/fcts packages.R

loopR Documentation

Looping over all individuals

Description

Extract the adjancency matrix and calculate network metrics for all individuals in a trajectory object. Also calculate mean speed, mean direction, and dot product of turning angles

Usage

loop(traj, res = 100)

Arguments

traj

An object produce by the function adehabitatLT with multiple individuals

res

Grid size, will be apply to all individuals

Value

A list object containing a raster stack object for each individual

Examples

data(puechabonsp)
locs <- puechabonsp$relocs
xy <- coordinates(locs)
df <- as.data.frame(locs)
da <- as.character(df$Date)
da <- as.POSIXct(strptime(as.character(df$Date),"%y%m%d", tz="Europe/Paris"))
litr <- as.ltraj(xy, da, id = id)
out1<-loop(litr)

BastilleRousseau/moveNT documentation built on Aug. 26, 2023, 5:54 a.m.