Change the appearance of ticks, tick labels, and gridlines. Tick properties that are not explicitly set using the keyword arguments remain unchanged unless *reset* is True. For the current style settings, see `.Axis.get_tick_params`. Parameters ----
(self, axis='both', **kwargs)
| 3603 | self.stale = True |
| 3604 | |
| 3605 | def tick_params(self, axis='both', **kwargs): |
| 3606 | """ |
| 3607 | Change the appearance of ticks, tick labels, and gridlines. |
| 3608 | |
| 3609 | Tick properties that are not explicitly set using the keyword |
| 3610 | arguments remain unchanged unless *reset* is True. For the current |
| 3611 | style settings, see `.Axis.get_tick_params`. |
| 3612 | |
| 3613 | Parameters |
| 3614 | ---------- |
| 3615 | axis : {'x', 'y', 'both'}, default: 'both' |
| 3616 | The axis to which the parameters are applied. |
| 3617 | which : {'major', 'minor', 'both'}, default: 'major' |
| 3618 | The group of ticks to which the parameters are applied. |
| 3619 | reset : bool, default: False |
| 3620 | Whether to reset the ticks to defaults before updating them. |
| 3621 | |
| 3622 | Other Parameters |
| 3623 | ---------------- |
| 3624 | direction : {'in', 'out', 'inout'} |
| 3625 | Puts ticks inside the Axes, outside the Axes, or both. |
| 3626 | length : float |
| 3627 | Tick length in points. |
| 3628 | width : float |
| 3629 | Tick width in points. |
| 3630 | color : :mpltype:`color` |
| 3631 | Tick color. |
| 3632 | pad : float |
| 3633 | Distance in points between tick and label. |
| 3634 | labelsize : float or str |
| 3635 | Tick label font size in points or as a string (e.g., 'large'). |
| 3636 | labelcolor : :mpltype:`color` |
| 3637 | Tick label color. |
| 3638 | labelfontfamily : str |
| 3639 | Tick label font. |
| 3640 | colors : :mpltype:`color` |
| 3641 | Tick color and label color. |
| 3642 | zorder : float |
| 3643 | Tick and label zorder. |
| 3644 | bottom, top, left, right : bool |
| 3645 | Whether to draw the respective ticks. |
| 3646 | labelbottom, labeltop, labelleft, labelright : bool |
| 3647 | Whether to draw the respective tick labels. |
| 3648 | labelrotation : float |
| 3649 | Tick label rotation angle in degrees. See `.Text.set_rotation`. |
| 3650 | labelrotation_mode : {'default', 'anchor', 'xtick', 'ytick'} |
| 3651 | Tick label rotation mode. See `.Text.set_rotation_mode`. |
| 3652 | grid_color : :mpltype:`color` |
| 3653 | Gridline color. |
| 3654 | grid_alpha : float |
| 3655 | Transparency of gridlines: 0 (transparent) to 1 (opaque). |
| 3656 | grid_linewidth : float |
| 3657 | Width of gridlines in points. |
| 3658 | grid_linestyle : str |
| 3659 | Any valid `.Line2D` line style spec. |
| 3660 | |
| 3661 | Examples |
| 3662 | -------- |