forecastML (version 0.5.0)

plot.training_results: Plot an object of class training_results

Description

Several diagnostic plots can be returned to assess the quality of the forecasts based on predictions on the validation datasets.

Usage

# S3 method for training_results
plot(x, type = c("prediction", "residual",
  "forecast_stability", "forecast_variability"), models = NULL,
  horizons = NULL, windows = NULL, valid_indices = NULL,
  group_filter = NULL, ...)

Arguments

x

An object of class 'training_results' from predict.forecast_mode()l.

type

Plot type. The default plot is "prediction" for validation dataset predictions.

models

Optional. Filter results by user-defined model name from train_model().

horizons

Optional. A numeric vector of model forecast horizons to filter results by horizon-specific model.

windows

Optional. A numeric vector of window numbers to filter results.

valid_indices

Optional. A numeric or date vector to filter results by validation row indices or dates.

group_filter

Optional. A string for filtering plot results for grouped time series (e.g., "group_col_1 == 'A'"). The results are passed to dplyr::filter() internally.

...

Not used.

Value

Diagnostic plots of class 'ggplot'.