lik_ar: Likelihood of an autoregressive time series model with i.i.d....

View source: R/scree_type.R

lik_arR Documentation

Likelihood of an autoregressive time series model with i.i.d. normal innovations

Description

Likelihood of an autoregressive time series model with i.i.d. normal innovations

Usage

lik_ar(x, ar, mean = 0, sd = 1, log = F, full = T)

Arguments

x

numeric vector of data

ar

vector of ar parameters

mean

the innovation mean

sd

the innovation standard deviation

log

logical; if TRUE, probabilities p are given as log(p)

full

logical; if TRUE, the full likelihood for all observations is computed; if FALSE, the partial likelihood for the last n-p observations

Value

numeric value for the likelihood or log-likelihood


beyondWhittle documentation built on May 31, 2023, 6:51 p.m.