etna.analysis.plot_forecast_decomposition#
- plot_forecast_decomposition(forecast_ts: TSDataset, test_ts: TSDataset | None = None, mode: Literal['per-component'] | Literal['joint'] = 'per-component', segments: List[str] | None = 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 (TSDataset | None) – TSDataset with timeseries data
mode (Literal['per-component'] | ~typing.Literal['joint']) –
Components plotting type
per-component
– plot each component in separate axesjoint
– plot all the components in the same axis
segments (List[str] | None) – 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 columnfigsize (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