Reputation: 43
How to plot pandas dataframe without labels while using
df.plot()
Edit: I still want to keep the ticks labels
Upvotes: 0
Views: 491
Reputation: 260640
df.plot()
returns a matplotlib Axes object, so use this to remove the axis:
df = pd.DataFrame([[1,2],[3,4]])
ax = df.plot()
ax.xaxis.set_visible(False)
ax.yaxis.set_visible(False)
output:
Upvotes: 1