AxesFormatterDecorator

class qf_lib.plotting.decorators.axes_formatter_decorator.AxesFormatterDecorator(x_major: matplotlib.ticker.Formatter = None, x_minor: matplotlib.ticker.Formatter = None, y_major: matplotlib.ticker.Formatter = None, y_minor: matplotlib.ticker.Formatter = None, use_secondary_axes: bool = False, key: str = None)[source]

Bases: qf_lib.plotting.decorators.chart_decorator.ChartDecorator

Creates a new Axes Formatter decorator that changes the way tickers in the x/y-axis are displayed.

See here for a list of valid axes formatters: http://matplotlib.org/api/ticker_api.html#tick-formatting.

Parameters
  • x_major (Formatter) –

  • x_minor (Formatter) –

  • y_major (Formatter) –

  • y_minor (Formatter) –

  • use_secondary_axes (bool) – use secondary axes (by default False)

  • key (str) – see: ChartDecorator.__init__#key

Methods

decorate(chart)

Modifies the axes object taken from the chart (e.g.

decorate(chart: Chart)[source]

Modifies the axes object taken from the chart (e.g. adds legend, draws cone, etc.).