A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://proplot.readthedocs.io/en/latest/api/proplot.constructor.Formatter.html below:

Formatter — ProPlot documentation

ProPlot Formatter
Formatter(formatter, *args, date=False, index=False, **kwargs)[source]

Return a Formatter instance.

Parameters

formatter (Formatter, str, bool, callable(), or sequence) – The formatter specification, interpreted as follows:

  • If a Formatter instance already, a copy.copy of the instance is returned.

  • If False, a NullFormatter is used, and if True, the default AutoFormatter is used.

  • If a function, the labels will be generated using this function. Returns a FuncFormatter.

  • If sequence of strings, the ticks are labeled with these strings. Returns a FixedFormatter by default or an IndexFormatter if index is True.

  • If a string containing {x} or {x:...}, ticks will be formatted by calling string.format(x=number). Returns a StrMethodFormatter.

  • If a string containing '%' and date is False, ticks will be formatted using the C-style string % number method. See this page for a review. Returns a FormatStrFormatter.

  • If a string containing '%' and date is True, ticks will be formatted using strfrtime. See this page for a review. Returns a DateFormatter.

Otherwise, formatter should be a string corresponding to one of the “registered” formatters or formatter presets (see below table). If formatter is a list or tuple and the first element is a “registered” formatter name, subsequent elements are passed to the formatter class as positional arguments. For example, pplt.Formatter(('sigfig', 3)) is equivalent to Formatter('sigfig', 3).

datebool, optional

Toggles the behavior when formatter contains a '%' sign (see above).

indexbool, optional

Controls the behavior when formatter is a sequence of strings (see above).

Other Parameters

*args, **kwargs – Passed to the Formatter class.

Returns

matplotlib.ticker.Formatter – A Formatter instance.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4