Reputation: 74
I have a scatter graph and I would like to change the x and y tick rates. Here is the graph I have:
As you can see, the x value tick rate increases at a 0.02 rate. I would like to change it to any other value. The same for the y axis.
Upvotes: 0
Views: 176
Reputation: 1763
You can do that by supplying the tick positions you want with plt.xticks
and plt.yticks
.
For example, for a spacing of 0.05 in x, use
step = 0.05
plt.xticks(np.arange(40.65, 40.85 + step, step))
Same for the y axis. Here, np
is numpy
.
Upvotes: 1