plot_feature_relevance(ts: TSDataset, relevance_table: etna.analysis.feature_relevance.relevance.RelevanceTable, normalized: bool = False, relevance_aggregation_mode: Union[str, Literal['per-segment']] = AggregationMode.mean, relevance_params: Optional[Dict[str, Any]] = None, top_k: Optional[int] = None, segments: Optional[List[str]] = None, columns_num: int = 2, figsize: Tuple[int, int] = (10, 5))[source]

Plot relevance of the features.

The most important features are at the top, the least important are at the bottom.

  • ts (TSDataset) – TSDataset with timeseries data

  • relevance_table (etna.analysis.feature_relevance.relevance.RelevanceTable) – method to evaluate the feature relevance

  • normalized (bool) – whether obtained relevances should be normalized to sum up to 1

  • relevance_aggregation_mode (Union[str, Literal['per-segment']]) – aggregation strategy for obtained feature relevance table; all the strategies can be examined at AggregationMode

  • relevance_params (Optional[Dict[str, Any]]) – additional keyword arguments for the __call__ method of RelevanceTable

  • top_k (Optional[int]) – number of best features to plot, if None plot all the features

  • segments (Optional[List[str]]) – segments to use

  • columns_num (int) – if relevance_aggregation_mode="per-segment" number of columns in subplots, otherwise the value is ignored

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