Learn R Programming

tidychangepoint (version 1.0.1)

fit_meanvar: Fit a model for mean and variance

Description

Fit a model for mean and variance

Usage

fit_meanvar(x, tau, ...)

Value

A mod_cpt object.

Arguments

x

A time series

tau

a set of indices representing a changepoint set

...

currently ignored

Details

In a mean-variance model, both the means and variances are allowed to vary across regions. Thus, this model fits a separate \(\mu_j\) and \(\sigma_j\) for each region \(j\).

See Also

changepoint::cpt.meanvar()

Other model-fitting: fit_arima(), fit_lmshift(), fit_meanshift(), fit_nhpp(), model_args(), model_name(), new_fun_cpt(), whomademe()

Examples

Run this code
# Fit a mean-variance model
fit_meanvar(CET, tau = c(42, 330))

Run the code above in your browser using DataLab