Package 'dyncomp'

Title: Complexity of Short and Coarse-Grained Time Series
Description: While there are many well-established measures for identifying critical fluctuations and phase transitions, these measures only work with many points of measurement and thus are unreliable when studying short and coarse-grained time series. This package provides a measure for complexity in a time series that does not rely on long time series (Kaiser (2017), <doi:10.17605/OSF.IO/GWTKX>).
Authors: Tim Kaiser
Maintainer: Tim Kaiser <[email protected]>
License: MIT + file LICENSE
Version: 0.0.2-1
Built: 2024-12-05 06:59:15 UTC
Source: CRAN

Help Index


Calculate dynamic complexity of time series

Description

A function to calculate the dynamic complexity of a series of observations, resulting from the degree of fluctuation and the degree of scattering. This measure is calculated in moving windows of a specified width, resulting in a series of values of a length equal to the length of the series of observations.

Usage

complexity(x, scaleMin, scaleMax, width = 7, measure = "complexity", rescale = FALSE)

Arguments

x

The data to be used (representing a series of observations).

scaleMin

Theoretical minimum of the data. Will default to the observed minimum of x.

scaleMax

Theoretical maximum of the data. Will default to the observed maximum of x.

width

Width of the moving window. Default is 7.

measure

Either "complexity", "fluctuation" or "distribution". Indicates which value should be returned. Default is "complexity".

rescale

If TRUE, rescales the returned values to scale minimum and maximum. This is sometimes useful for graphical interpretation or plotting. Default: FALSE.

Author(s)

Tim Kaiser <[email protected]>

References

Kaiser, T. (2017). dyncomp: an R package for Estimating the Complexity of Short Time Series. DOI 10.17605/OSF.IO/GWTKX

Examples

t <- runif(100, 0, 10)
c <- complexity(x = t, scaleMin = 0, scaleMax = 10, width = 5, measure = "complexity",
rescale = TRUE)
plot(t, type = "l")
lines(c, col = "red", lty = 4)