Bokeh figures in LaTex and pdf


Please could you help me? I am new to Bokeh.

I am going to prepare an analysis of measured data.

  1. I would like to prepare a technical report and presentation of the analysis in the LaTex Article and Beamer Presentation. I would like to insert interactive figures in the report and presentation. Finally, I will convert the article and presentation to pdf format.

  2. I would like to store stand-alone interactive figures.

I am not sure whether I can do it with the Bokeh library. It seems to me, that with Bokeh I can prepare interactive figures in the Internet Browser.

In case I can use interactive figures with LaTex and pdf, please, let me know the basic steps.

In case I can’t use Bokeh interactive figures with LaTex and pdf is there any way?


Definitely not possible with Bokeh. Bokeh output is actually essentially a JavaScript program that executes, and it is that execution that affords the interactivity. UI events can trigger JavaScript callbacks that update a plot, etc. and that loop is the basis for all interactivity. “Live” Bokeh plots require a JavaScript runtime engine, full stop. The only thing you could do here is use the Bokeh APIs for exporting output to PNG or SVG, and include those static images.

In case I can’t use Bokeh interactive figures with LaTex and pdf is there any way?

Probably not? AFAIK the PDF format does not have any features in it that would afford true interactive content. I think you can embed videos and maybe animated images, but that’s not interactive, really. (However, I could be mistaken, or ignorant of recent developments to the PDF standard).

Thank you Bryan for the quick response.