How can I change the hover text on the x-axis?

When I hover, in the x-axis this is the info showed.
plotly

It is a percentage value. I would like to add the absolute value,
and insted of just β€œ77.3”, show something like β€œ77.3% (4313 times)”

I did it for y-axis info.
plotly2

But I can’t for x-axis.

Thank you!!

@alangb

Try the same method like for yaxis, but for xaxis make the following update:

fig.update_xaxes(tickangle=-45)  # or tickangle=45

I think in your attempt it didn’t work for xaxis, because the ticklabel string is too long. It is possible that the above set tickangle to lead to the desired plot.