You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jun 3, 2024. It is now read-only.
I couldn't seem to find this in the docs. Is it possible to format hover_data as a string for display purposes only? My use case comes from displaying dollar amounts, but the original data is float.64 so hovering over a data point does not look appealing.
My current fix requires an extra column to be added to a data frame, then that column is passed to the hover_data argument:
df['hover_text'] = df['revenue'].apply(lambda x :'${0:,.0f}'.format(x))
However, this is not a great solution. My knowledge is pretty limited with plotly so there may be better solutions I haven't been able to find currently. Perhaps with hovertemplate?