Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork7.9k
Closed
Labels
Milestone
Description
As reported by @wuweihust on gitter, string categorical tick labels don't show up in the preview window of an interactive plot:
%matplotlibnotebookimportmatplotlib.pyplotaspltfig,ax=plt.subplots()ax.plot(['hi','bye','why'], [3,1,2])
On gitter,@jklymak recommend implementing theformat_data_short
method for theStrCategoryFormatter.
The implementation should probably be something like thedefault:
defformat_data(self,value):returnself.__call__(value)defformat_data_short(self,value):returnself.format_data(value)
Which, as an aside, why aren't these called givenStrCategoryFormatter
inherits fromFormatter
?