Skip to contents

This function removes ARIMA terms — arima(), ar(), ma(), and arma() — from a formula so they can be processed on their own.

Usage

remove_arima_terms(formula)

Arguments

formula

A model formula that may use standard fixed effects, random effects using lme4 syntax (see re()), and random walks defined using the rw() helper function. See the Details section below for a comprehensive explanation of the supported syntax.

Value

A formula object with the ARIMA terms removed.

Examples

epinowcast:::remove_arima_terms(~ 1 + age_group + arima(week))
#> ~1 + age_group
#> <environment: 0x56337a410c30>
epinowcast:::remove_arima_terms(~ 1 + age_group + ar(week, p = 2))
#> ~1 + age_group
#> <environment: 0x56338603efa0>