Learn R Programming

CoSMoS (version 2.2.0)

fitACS: Autocorrelation structure fitting

Description

Fits a parametric autocorrelation structure (ACS) to empirical ACF values using Nelder-Mead optimisation with MSE criterion.

Usage

fitACS(acf, ID, start = NULL, lag = NULL)

Value

An object of class "fitACS": a named list of fitted ACS parameters with attributes ID and eACS (empirical ACS used for fitting).

Arguments

acf

numeric vector of autocorrelation function values from lag 0

ID

character; ACS identifier (e.g. "weibull", "paretoII")

start

numeric vector of starting parameter values; if NULL, all parameters start at 1

lag

integer; number of lags to use; if NULL, lags up to the first value \(\le 0.01\) are used (or all lags if none drops below 0.01)

See Also

fitDist, plot.fitACS, acs

Examples

Run this code

x <- arima.sim(model = list(ar = 0.8), n = 1000)

acsfit <- fitACS(acf(x, plot = FALSE)$acf, "weibull", c(1, 1))

Run the code above in your browser using DataLab