fit.ucarima: Estimation of UCARIMA models

View source: R/ucarima.R

fit.ucarimaR Documentation

Estimation of UCARIMA models

Description

Estimates the parameters of a UCARIMA model using maximum likelihood.

Usage

## S3 method for class 'ucarima'
fit(mdl, z = NULL, method = "BFGS", show.iter = FALSE, envir = NULL, ...)

Arguments

mdl

An object of class ucarima.

z

Optional. A time series object (ts) used for estimation if not already included in mdl.

method

Character string specifying the optimization method passed to optim. Default is "BFGS".

show.iter

Logical. If TRUE, displays parameter estimates during each iteration of the optimization process. Default is FALSE.

envir

Environment where the estimation is evaluated. If NULL (default), uses the parent environment.

...

Additional arguments passed to optim.

Value

An updated ucarima object with estimated parameters, log-likelihood, and convergence information.

Examples

# Define a local level model with trend and irregular components
trend <- um(i = 1, sig2 = c(s2t = 0.5))
irreg <- um(sig2 = c(s2i = 1))

# Create and estimate the UCARIMA model
uca <- ucarima(ucm = list(trend = trend, irreg = irreg))
uca_fitted <- fit(uca, Nile)


tfarima documentation built on Nov. 5, 2025, 7:43 p.m.