unicor: Autocovariance and Autocorrelation

unicorR Documentation

Autocovariance and Autocorrelation

Description

Compute autocovariance and autocorrelation function of the univariate time series.

Usage

unicor(y, lag = NULL, minmax = c(-1.0e+30, 1.0e+30), plot = TRUE, ...)

Arguments

y

a univariate time series.

lag

maximum lag. Default is 2 \sqrt{n}, where n is the length of the time series y.

minmax

thresholds for outliers in low side and high side.

plot

logical. If TRUE (default), autocorrelations are plotted.

...

graphical arguments passed to the plot method.

Value

An object of class "unicor" which has a plot method. This is a list with the following components:

acov

autocovariances.

acor

autocorrelations.

acov.err

error bound for autocovariances.

acor.err

error bound for autocorrelations.

mean

mean of y.

tsname

the name of the univariate time series y.

References

Kitagawa, G. (2020) Introduction to Time Series Modeling with Applications in R. Chapman & Hall/CRC.

Examples

# Yaw rate, rolling, pitching and rudder angle of a ship
data(HAKUSAN)
Yawrate <- HAKUSAN[, 1]
unicor(Yawrate, lag = 50)

# seismic data
data(MYE1F)
unicor(MYE1F, lag = 50)

TSSS documentation built on Sept. 29, 2023, 9:07 a.m.