Tuesday, 6 August 2013

formatting secondary y axis in pandas

formatting secondary y axis in pandas

I am plotting a pandas DataFrame with several columns as below:
fig, ax = py.subplots(figsize=(11.7, 8.3))
df.plot(ax=ax, secondary_y=[A])
I can format the primary yaxis with a command as below:
ax.yaxis.set_major_formatter(FormatStrFormatter('%d days'))
How can I apply formatting to the secondary Y-axis (the one that displays
on the right)?

No comments:

Post a Comment