remove axis labels in matplotlib
February 27th, 2012 by Lawrence David
to remove the labels of the x-axis:
ax.get_xaxis().set_ticks([])
to remove the labels of the y-axis:
ax.get_yaxis().set_ticks([])
UPDATE (w/ Matplotlib 1.3):
An even easier way:
pl.tick_params(labeltop=False, labelbottom=False, bottom=False, top=False, labelright=True)