Skip to content

Commit f390d04

Browse files
authored
Sanity check for ticklabelsize()
1 parent 0bf9ec0 commit f390d04

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

yaptool.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -419,6 +419,9 @@ def ticklabelsize(ax: plt.Axes, which: str = "both", size: float = 30) -> None:
419419
Returns:
420420
None
421421
"""
422+
if not which in ["x", "y", "xy", "yx", "both"]:
423+
raise ValueError(
424+
'Parameter which must be one of "x", "y", "xy", "yx", "both".')
422425

423426
if not hasattr(ax, 'plot'):
424427
raise ValueError("Pass a valid plot in parameter ax.")

0 commit comments

Comments
 (0)