plot_forecast_decomposition

plot_forecast_decomposition(forecast_ts: TSDataset, test_ts: Optional[TSDataset] = None, mode: Union[Literal['per-component'], Literal['joint']] = 'per-component', segments: Optional[List[str]] = None, columns_num: int = 1, figsize: Tuple[int, int] = (10, 5), show_grid: bool = False)[source]

Plot of prediction and its components.

Parameters
  • forecast_ts (TSDataset) – forecasted TSDataset with timeseries data, single-forecast mode

  • test_ts (Optional[TSDataset]) – TSDataset with timeseries data

  • mode (Union[Literal['per-component'], typing.Literal['joint']]) –

    Components plotting type

    1. per-component – plot each component in separate axes

    2. joint – plot all the components in the same axis

  • segments (Optional[List[str]]) – segments to plot; if not given plot all the segments

  • columns_num (int) – number of graphics columns; when mode=``per-component`` all plots will be in the single column

  • figsize (Tuple[int, int]) – size of the figure per subplot with one segment in inches

  • show_grid (bool) – whether to show grid for each chart

Raises
  • ValueError: – if components aren’t present in forecast_ts

  • NotImplementedError: – unknown mode is given