File tree Expand file tree Collapse file tree 1 file changed +20
-7
lines changed Expand file tree Collapse file tree 1 file changed +20
-7
lines changed Original file line number Diff line number Diff line change @@ -5,12 +5,25 @@ The new `~matplotlib.axis.Axis.get_tick_params` method can be used to
5
5
retrieve the appearance settings that will be applied to any
6
6
additional ticks, tick labels, and gridlines added to the plot:
7
7
8
- .. code-block :: python
8
+ .. code-block :: pycon
9
9
10
- import matplotlib.pyplot as plt
10
+ >>> import matplotlib.pyplot as plt
11
11
12
- fig, ax = plt.subplots()
13
- ax.yaxis.set_tick_params(labelsize = 30 , labelcolor = ' red' ,
14
- direction = ' out' , which = ' major' )
15
- print (ax.yaxis.get_tick_params(which = ' major' ))
16
- print (ax.yaxis.get_tick_params(which = ' minor' ))
12
+ >>> fig, ax = plt.subplots()
13
+ >>> ax.yaxis.set_tick_params(labelsize=30, labelcolor='red',
14
+ ... direction='out', which='major')
15
+ >>> ax.yaxis.get_tick_params(which='major')
16
+ {'direction': 'out',
17
+ 'left': True,
18
+ 'right': False,
19
+ 'labelleft': True,
20
+ 'labelright': False,
21
+ 'gridOn': False,
22
+ 'labelsize': 30,
23
+ 'labelcolor': 'red'}
24
+ >>> ax.yaxis.get_tick_params(which='minor')
25
+ {'left': True,
26
+ 'right': False,
27
+ 'labelleft': True,
28
+ 'labelright': False,
29
+ 'gridOn': False}
You can’t perform that action at this time.
0 commit comments