5

I would like to embed a Bokeh plot (from IPython notebook) into my blog as an svg file. Is there currently a way to save the plots as svg's?

I tried to look in the documentation, but it's a little unclear.

NoDataDumpNoContribution
  • 10,591
  • 9
  • 64
  • 104
Anarcho-Chossid
  • 2,210
  • 4
  • 27
  • 44
  • Looks like this feature - saving plots as svg, png, etc. - is scheduled for release any day in Bokeh 0.8. https://groups.google.com/a/continuum.io/forum/#!searchin/bokeh/svg/bokeh/biqOu8T23l0/L2yxwHSx3nQJ – Jubbles Feb 14 '15 at 22:24
  • 2
    Possible duplicate of [Exporting figures from Bokeh as svg or pdf?](http://stackoverflow.com/questions/24026618/exporting-figures-from-bokeh-as-svg-or-pdf) – Fabian Rost Mar 01 '16 at 14:08
  • 1
    Possible duplicate of [With Bokeh, how to save to a png or jpg instead of a html file?](https://stackoverflow.com/questions/24060173/with-bokeh-how-to-save-to-a-png-or-jpg-instead-of-a-html-file) – tupui Jul 25 '17 at 10:12

1 Answers1

5

This is now possible! From the doc:

from bokeh.io import export_svgs

plot.output_backend = "svg"
export_svgs(plot, filename="plot.svg")
tupui
  • 5,738
  • 3
  • 31
  • 52