☰Read-only archive⌕
Looking for help with Bokeh?

This is a read-only archive. Ask questions and join the conversation on GitHub.

Visit Community Support on GitHub →
Archived discussions · Captured October 28, 2026

using event attribute in CustomJS callback

Community Support
nsp
nsp

I have used bokeh to create an html file with two plots. I want the second plot to respond to a double click on the first plot using the x-axis value of the location of the double click. Is there a simple way to accomplish this? My knowledge of JavaScript is very limited. Thank you!

⌁   Link to post
Bryan
Bryan

Hi,

It's often possible to achieve sophisticated linked behavior in only a few (<10) lines of JS. I'd suggest studying the examples here:

  http://bokeh.pydata.org/en/latest/docs/user_guide/interaction/callbacks.html#userguide-interaction-jscallbacks

To get some ideas, and be able to formulate more concrete questions based on your particular use case.

Thanks,

Bryan

···

On Oct 25, 2017, at 09:04, nsp <nspeml@gmail.com> wrote:

I have used bokeh to create an html file with two plots. I want the second plot to respond to a double click on the first plot using the x-axis value of the location of the double click. Is there a simple way to accomplish this? My knowledge of JavaScript is very limited. Thank you!

--
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 bokeh+unsubscribe@continuum.io.
To post to this group, send email to bokeh@continuum.io.
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/ec77843c-335d-4d16-be63-956e53529de2%40continuum.io\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.

⌁   Link to post
nsp
nsp

Was able to do it by following the examples in the link posted by Bryan!

···

On Wednesday, October 25, 2017 at 5:46:39 PM UTC+2, Bryan Van de ven wrote:

Hi,

It’s often possible to achieve sophisticated linked behavior in only a few (<10) lines of JS. I’d suggest studying the examples here:

    [http://bokeh.pydata.org/en/latest/docs/user_guide/interaction/callbacks.html#userguide-interaction-jscallbacks](http://bokeh.pydata.org/en/latest/docs/user_guide/interaction/callbacks.html#userguide-interaction-jscallbacks)

To get some ideas, and be able to formulate more concrete questions based on your particular use case.

Thanks,

Bryan

On Oct 25, 2017, at 09:04, nsp nsp...@gmail.com wrote:

I have used bokeh to create an html file with two plots. I want the second plot to respond to a double click on the first plot using the x-axis value of the location of the double click. Is there a simple way to accomplish this? My knowledge of JavaScript is very limited. Thank you!

–
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 bokeh+un...@continuum.io.

To post to this group, send email to bo...@continuum.io.

To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/ec77843c-335d-4d16-be63-956e53529de2%40continuum.io.

For more options, visit https://groups.google.com/a/continuum.io/d/optout.

⌁   Link to post

End of archived discussion · Replies are disabled