I am trying to plot histogram data with pandas and matplotlib. I am using the dataframe.plot() function. The problem is, that this generates a graph with a lot of displayed ticks on the x-axis.
histogram plot
The index of the dataframe is used as ticks. Here is the code:
fig, axes = plt.subplots(figsize=(12,12))
PLOT_CONFIG_HISTOGRAM={
"subplots":True,
"title":"cyclictest wakeup latency",
"legend":True,
"xlabel":"latency/us",
"ylabel":"cycles",
"logy":True,
"kind":"bar",
}
my_dataframe.plot(ax=axes,**PLOT_CONFIG_HISTOGRAM)
Is there a way in matplotlib or pandas to reduce the displayed ticks? Or a better way to display histogram data?
In the end should be something like this:
| | | | |
| |
1 5
or like this:
| |
1 5
Thanks in advance for any input.