graphinglib.SmartTwinAxis.set_tick_params#

SmartTwinAxis.set_tick_params(which: Literal['major', 'minor', 'both'] | None = 'major', reset: bool = False, direction: Literal['in', 'out', 'inout'] | None = None, length: float | None = None, width: float | None = None, color: str | None = None, pad: float | None = None, label_size: float | str | None = None, label_color: str | None = None, label_rotation: float | None = None, draw_ticks: bool | None = None, draw_labels: bool | None = None) Self[source]#

Sets the tick parameters. These parameters are given to the matplotlib.axes.Axes.tick_params() method.

Parameters:
which{“major”, “minor”, “both”}, optional

The ticks to set the parameters for. This method can be called multiple times to set the tick parameters specifically for each ticks type. Defaults to "major".

resetbool, optional

If True, resets all previously given tick parameters to their default values before applying the new parameters. Defaults to False.

direction{“in”, “out”, “inout”}, optional

The direction of the ticks.

lengthfloat, optional

The length of the ticks. Typical range is 2 to 10.

widthfloat, optional

The width of the ticks. Typical range is 0.5 to 3.

colorstr, optional

The color of the ticks.

padfloat, optional

The padding to add between the tick labels and the ticks themselves. Typical range is 2 to 10.

label_sizefloat | str, optional

The font size of the tick labels. This can be a float or a string (e.g. “large”). Typical range is 8 to 20 when a float is used.

label_colorstr, optional

The color of the tick labels.

label_rotationfloat, optional

The rotation of the tick labels, in degrees.

draw_ticksbool, optional

Whether to draw the ticks of the axis.

draw_labelsbool, optional

Whether to draw the tick labels of the axis.

Returns:
Self

For convenience, the same SmartFigure with the updated tick parameters.

Notes

Color parameters accept Matplotlib color formats: named colors ("blue"), short color strings ("b"), hex strings ("#0000ff"), grayscale strings ("0.5"), and RGB/RGBA tuples with values between 0 and 1 ((0, 0, 1) or (0, 0, 1, 0.5)).