autocti.plot.YTicks#
- class autocti.plot.YTicks(manual_factor: Optional[float] = None, manual_values: Optional[List[float]] = None, manual_min_max_value: Optional[Tuple[float, float]] = None, manual_units: Optional[str] = None, manual_suffix: Optional[str] = None, **kwargs)[source]#
Bases:
AbstractTicksThe settings used to customize a figure’s y and x ticks using the YTicks and XTicks objects.
This object wraps the following Matplotlib methods:
plt.yticks: https://matplotlib.org/3.3.1/api/_as_gen/matplotlib.pyplot.yticks.html
plt.xticks: https://matplotlib.org/3.3.1/api/_as_gen/matplotlib.pyplot.xticks.html
- Parameters:
manual_values – Manually override the tick labels to display the labels as the input list of floats.
manual_units – Manually override the units in brackets of the tick label.
manual_suffix – A suffix applied to every tick label (e.g. for the suffix kpc 0.0 becomes 0.0kpc).
Methods
factor_fromlabels_fromnumber_of_ticks_fromSet the y ticks of a figure using the shape of an input Array2D object and input units.
tick_maker_fromticks_and_labels_fromticks_fromAttributes
config_categoryconfig_dictconfig_folder- set(min_value: float, max_value: float, units: Units, pixels: Optional[int] = None, yunit=None, is_for_1d_plot: bool = False, is_log10: bool = False)[source]#
Set the y ticks of a figure using the shape of an input Array2D object and input units.
- Parameters:
array – The 2D array of data which is plotted.
min_value – the minimum value of the yticks that figure is plotted using.
max_value – the maximum value of the yticks that figure is plotted using.
units – The units of the figure.