autocov2MA: MA process compatible with a vector of autocovariances

View source: R/utils.R

autocov2MAR Documentation

MA process compatible with a vector of autocovariances

Description

autocov2MA computes the error variance and the MA polynomial from a vector of autocovriances.

Usage

autocov2MA(x, method = c("roots", "acov"), tol = 1e-05)

Arguments

x

a numeric vector with q autocovariances.

method

character. Two methods are provided to compute the MA parameters: roots, based on the roots of the autocovariance generating function; acov, based on the non-linear system of equations relating autocovariances and MA parameters.

tol

tolerance to check if an autocovariance is null.

Value

A vector of the form c(s2, 1, -theta1, ..., -thetaq).

Examples

ma1 <- um(ma = "1 - 0.8B", sig2 = 0.5)
autocov2MA(autocov(ma1, 1))
autocov2MA(autocov(ma1, 1), "acov")

gallegoj/tfarima documentation built on March 31, 2024, 10:32 a.m.