Bokeh tooltip doesn't work properly on Numeric x-axis column

Hello,

I created a bar chart using bokeh python. Now, I add tooltip over bars.

When I use numeric value in x_axis_column. It doesn’t show tooltip.

But when I use string value in x_axis_column, it shows tooltip properly.

Code:

from bokeh.charts import Bar, output_file, show
import pandas as pd
df = pd.read_csv("bar.csv")
x_axis_column = "x"
plot = Bar(df, values='count', label=x_axis_column,legend=False, tooltips=[('count', '@height')], color="red")
output_file("bar.html")

show(plot)

Where, x_axis_column is integer type, tooltip doesn’t work but when I use x_axis_column values as string data type, then tooltip works.

P.S. You can view the same question on Stackoverflow.

Thanks,

Nitin

This e-mail, including any attached files, may contain confidential and privileged information for the sole use of the intended recipient. Any review, use, distribution, or disclosure by others is strictly prohibited. If you are not the intended recipient (or authorized to receive information for the intended recipient), please contact the sender by reply e-mail and delete all copies of this message.

Hi,

I am afraid I have more bad news for you, the bokeh.charts API has been recently removed to a separate repo and project project. This is because the original people that created bokeh.charts no longer work on it, and it is effectively unmaintained at this point. There is another very high level library built on top of Bokeh that is maintained by an active team, called Holoviews: http://holoviews.org We will have more to say about Holoviews+Bokeh in the near future (there will be a vey big new release of HV next week) but I would encourage looking at it, before looking at bkcharts.

Thanks,

Bryan

···

On Jun 9, 2017, at 03:51, Nitin Solanki <[email protected]> wrote:

Hello,

I created a bar chart using bokeh python. Now, I add tooltip over bars.

When I use numeric value in x_axis_column. It doesn't show tooltip.

But when I use string value in x_axis_column, it shows tooltip properly.

Code:

from bokeh.charts import Bar, output_file,
show

import pandas as
pd
df
= pd.read_csv("bar.csv")

x_axis_column
= "x"

plot
= Bar(df, values='count', label=x_axis_column,legend=False, tooltips=[('count', '@height')], color="red")

output_file
("bar.html")

show
(plot)
Where, x_axis_column is integer type, tooltip doesn't work but when I use x_axis_column values as string data type, then tooltip works.

P.S. You can view the same question on Stackoverflow.

Thanks,

Nitin

This e-mail, including any attached files, may contain confidential and privileged information for the sole use of the intended recipient. Any review, use, distribution, or disclosure by others is strictly prohibited. If you are not the intended recipient (or authorized to receive information for the intended recipient), please contact the sender by reply e-mail and delete all copies of this message.

--
You received this message because you are subscribed to the Google Groups "Bokeh Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/CAOUEs4Xdc6gAu2C92AsL-32V7p9KcRT6f1oGkh7ETqf-ZvzD6w%40mail.gmail.com.
For more options, visit https://groups.google.com/a/continuum.io/d/optout.

Also, here is a preview of the upcoming Holoviews gallery:

  http://build.holoviews.org/gallery/index.html

Bryan

···

On Jun 9, 2017, at 08:06, Bryan Van de ven <[email protected]> wrote:

Hi,

I am afraid I have more bad news for you, the bokeh.charts API has been recently removed to a separate repo and project project. This is because the original people that created bokeh.charts no longer work on it, and it is effectively unmaintained at this point. There is another very high level library built on top of Bokeh that is maintained by an active team, called Holoviews: http://holoviews.org We will have more to say about Holoviews+Bokeh in the near future (there will be a vey big new release of HV next week) but I would encourage looking at it, before looking at bkcharts.

Thanks,

Bryan

On Jun 9, 2017, at 03:51, Nitin Solanki <[email protected]> wrote:

Hello,

I created a bar chart using bokeh python. Now, I add tooltip over bars.

When I use numeric value in x_axis_column. It doesn't show tooltip.

But when I use string value in x_axis_column, it shows tooltip properly.

Code:

from bokeh.charts import Bar, output_file,
show

import pandas as
pd
df
= pd.read_csv("bar.csv")

x_axis_column
= "x"

plot
= Bar(df, values='count', label=x_axis_column,legend=False, tooltips=[('count', '@height')], color="red")

output_file
("bar.html")

show
(plot)
Where, x_axis_column is integer type, tooltip doesn't work but when I use x_axis_column values as string data type, then tooltip works.

P.S. You can view the same question on Stackoverflow.

Thanks,

Nitin

This e-mail, including any attached files, may contain confidential and privileged information for the sole use of the intended recipient. Any review, use, distribution, or disclosure by others is strictly prohibited. If you are not the intended recipient (or authorized to receive information for the intended recipient), please contact the sender by reply e-mail and delete all copies of this message.

--
You received this message because you are subscribed to the Google Groups "Bokeh Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/CAOUEs4Xdc6gAu2C92AsL-32V7p9KcRT6f1oGkh7ETqf-ZvzD6w%40mail.gmail.com.
For more options, visit https://groups.google.com/a/continuum.io/d/optout.