Skip to contents

Detect structural breaks in functional time series using elastic methods. Elastic Changepoint Detection

Usage

elastic.changepoint(
  fdataobj,
  type = c("amplitude", "phase", "fpca"),
  pca.method = c("vertical", "horizontal", "joint"),
  ncomp = 3,
  lambda = 0,
  max.iter = 20,
  n.mc = 1000,
  cov.kernel = c("bartlett", "parzen", "flattop", "simple"),
  cov.bandwidth = NULL,
  seed = NULL
)

Arguments

fdataobj

An object of class 'fdata'. Curves should be in temporal order (rows = time points in the series).

type

Type of changepoint test: "amplitude" (shape changes), "phase" (timing changes), or "fpca" (combined via elastic FPCA).

pca.method

PCA method for type = "fpca": "vertical", "horizontal", or "joint".

ncomp

Number of FPC components for type = "fpca" (default 3).

lambda

Regularization for alignment (default 0).

max.iter

Maximum alignment iterations (default 20).

n.mc

Number of Monte Carlo permutations for p-value (default 1000).

cov.kernel

Deprecated. No longer used (ignored with a warning).

cov.bandwidth

Deprecated. No longer used (ignored with a warning).

seed

Random seed for reproducibility.

Value

An object of class 'elastic.changepoint' with components:

changepoint

Estimated changepoint index (1-based)

test.statistic

Value of the CUSUM test statistic

p.value

Permutation-based p-value

cusum.values

Full CUSUM process values

type

Type of test performed

n

Number of curves in the series

Details

Tests for a changepoint in a functional time series using amplitude, phase, or FPCA-based test statistics with permutation-based p-values.

Examples

# \donttest{
fd <- fdata(matrix(rnorm(500), 50, 10), argvals = seq(0, 1, length.out = 10))
cp <- elastic.changepoint(fd, type = "amplitude", n.mc = 100)
cp
#> Elastic Changepoint Detection
#>   Type: amplitude 
#>   Changepoint at: 24 of 50 curves
#>   Test statistic: 0.003486 
#>   p-value: 0.7822 
# }