timelag: Time lag analysis

Description Usage Arguments Details Value Author(s) Examples

Description

Time lag analysis for a multivariate data set

Usage

1
2
3
4
timelag(x, ...)

## S3 method for class 'dist'
timelag(x, ...)

Arguments

x

an R object. Only objects of class "dist" are currently supported.

...

additional arguments passed to other methods.

Details

Time lag analysis involves computing the compositional dissimilarity between samples at lag 1, at lag 2, etc, then the least squares slope between sqrt(lag) and dissimilarity.

Value

Returns an object of class "timelagAnalysis", a list with components

data

data frame; unpacked set of lags (Lag) and compositional dissimilarities (Distance).

Author(s)

Gavin L. Simpson

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
## load analogue for Abernethy data set & distance()
if (require("analogue")) {

## Load Abernethy Forest data set
data("abernethy", package = "analogue")
## Load Abernethy Forest data set

## Remove the Depth and Age variables
abernethy2 <- abernethy[, -(37:38)]

## time lag analysis
dij <- as.dist(distance(abernethy2, method = "chord"))
tla <- timelag(dij)
head(tla[[1]])
}

gavinsimpson/temporalEF documentation built on May 16, 2019, 10:11 p.m.