Questions tagged [bokeh]

Bokeh is a library for interactive visualization (including streaming or large datasets) that targets modern web browsers for presentation, and high level languages such as Python, Scala, and R for use.

Bokeh is an interactive visualization library for high level languages such Python, R and Scala, that natively targets modern web technologies. It is easily embeddable in common web-frameworks and can be used for standalone interactive documents, or server-backed data applications for large and streaming datasets.

4729 questions
17
votes
1 answer

Automatically fit Bokeh plot to screen?

Is there a simple way to automatically fit a Bokeh plot to the screen used to display your browser? Right now I'm setting the plot width and height manually. Note: when I say fit I mean that I want the plot to fill 80% of the visible screen.
user2757762
17
votes
6 answers

Can I plot a colorbar for a bokeh heatmap?

Does bokeh have a simple way to plot the colorbar for a heatmap? In this example it would be a strip illustrating how colors correspond to values. In matlab, its called a 'colorbar' and looks like this:
bs123
  • 1,183
  • 3
  • 11
  • 21
17
votes
2 answers

Turning off Tick Marks in Bokeh

I am working on the Bokeh (0.6.1) tutorial and trying to turn off the tick marks and labels in one of the exercise plots, the scatter plot: from __future__ import division import numpy as np from six.moves import zip from bokeh.plotting import…
daedalus
  • 10,873
  • 5
  • 50
  • 71
16
votes
3 answers

Python: Bokeh hover date time

I am trying to get a line plot via Bokeh in Python. I am new to Bokeh and I am trying to apply hover tool tips over the plot. The x-axis of the plot has Timestamp values which are converted into epoch string. I've reviewed some same problems here…
Yasir Azeem
  • 298
  • 2
  • 4
  • 13
16
votes
1 answer

Dynamically add/remove plot using 'bokeh serve' (bokeh 0.12.0)

My question is quite similar to another thread using bokeh 0.7.1, but the API for bokeh servers has changed enough in 0.12.0, that I am struggling to adapt that answer to the new version. To summarize, I have a page with a grid of timestream plots…
Adam Anderson
  • 173
  • 1
  • 5
16
votes
2 answers

How to add a Callback to Bokeh DataTable?

I am trying to use Bokeh to make an editable DataTable that updates the source data when the data is edited. I started with the standard DataTable example here, and make the editable kwarg to true. Here is where I am at: from datetime import…
Kyle Siegel
  • 733
  • 1
  • 7
  • 8
16
votes
1 answer

How do you add error bars to Bokeh plots in python?

I have successfully plotted several data sets and fitted functions using Bokeh however I really need to add error bars to the graphs, how might I go about doing this?
airdas
  • 872
  • 2
  • 11
  • 19
16
votes
2 answers

HoverTool for multiple data series in bokeh scatter plot

I have the following small example script making use of numpy and bokeh: import numpy as np import bokeh.plotting as bp from bokeh.objects import HoverTool bp.output_file('test.html') fig = bp.figure(tools="reset,hover") x =…
Max
  • 335
  • 1
  • 3
  • 12
16
votes
1 answer

Bokeh's equivalent to matplotlib subplots

I am looking for a way to create a plot the containing several subplots like fig, (ax0, ax1) = plt.subplots(nrows=2, sharex=True) would do in matplotlib, which then can be addressed by ax0 and ax1. Is there a way to do something similar in Bokeh?…
greole
  • 4,523
  • 5
  • 29
  • 49
16
votes
2 answers

Embedding a plot in a website with Python/bokeh

I am trying to statically embed a bokeh plot in a personal website, and am encountering some behavior I do not understand. Basically, I am generating a plot using bokeh as follows: import bokeh.plotting as bplt import numpy as…
Mike
  • 1,727
  • 3
  • 15
  • 25
15
votes
2 answers

set title of a python `bokeh` plot figure from outside of the `figure()` function

I ran into a very seemingly simple problem when using the bokeh plotting package in python. I wanted to set the title of a bokeh figure from outside of the usual figure constructor, but I get a strange error. Here is the code. from bokeh.plotting…
krishnab
  • 9,270
  • 12
  • 66
  • 123
15
votes
3 answers

How to add data labels to a bar chart in Bokeh?

In the Bokeh guide there are examples of various bar charts that can be created. http://docs.bokeh.org/en/0.10.0/docs/user_guide/charts.html#id4 This code will create one: from bokeh.charts import Bar, output_file, show from bokeh.sampledata.autompg…
sparrow
  • 10,794
  • 12
  • 54
  • 74
15
votes
3 answers

What's the command to "reset" a bokeh plot?

I have a bokeh figure that has a reset button in the toolbar. Basically, I want to "reset" the figure when I update the data that I'm plotting in the figure. How can I do that?
user1340654
  • 395
  • 2
  • 5
  • 16
15
votes
6 answers

How do I link the CrossHairTool in bokeh over several plots?

When moving the crosshair (dimensions=width) in one plot I want to see the same position in the other plot(s). My plots share the same x-axis. Here is the plot setup and an example: #!/usr/bin/env python # -*- coding: utf-8 -*- from bokeh.plotting…
karsten
  • 151
  • 1
  • 5
15
votes
6 answers

Displaying only one tooltip when using the HoverTool() tool

I am plotting very many points in Bokeh, and I have added the HoverTool to the list of tools of the figure, so that the mouse shows the x,y coordinates of the mouse when close to a glyph. When the mouse gets close to a set of glyphs closely packed…
gg349
  • 21,996
  • 5
  • 54
  • 64