reconcile: Forecast reconciliation

View source: R/reconciliation.R

reconcileR Documentation

Forecast reconciliation

Description

This function allows you to specify the method used to reconcile forecasts in accordance with its key structure.

Usage

reconcile(.data, ...)

## S3 method for class 'mdl_df'
reconcile(.data, ...)

Arguments

.data

A mable.

...

Reconciliation methods applied to model columns within .data.

Examples


library(fable)
lung_deaths_agg <- as_tsibble(cbind(mdeaths, fdeaths)) %>%
  aggregate_key(key, value = sum(value))

lung_deaths_agg %>%
  model(lm = TSLM(value ~ trend() + season())) %>%
  reconcile(lm = min_trace(lm)) %>% 
  forecast()


fabletools documentation built on Oct. 12, 2023, 1:07 a.m.