Live Plot in Jupyter notebook using Bokeh

Dear all,

I am completely new to Bokeh and I would like to create a live plot. Baically I am controlling electronic instruments that send me some data let’s say every few seconds that I would like to display. I would like to be able to interract with the graph (zooming for example) without disrupting the data acquisition. I don’t need super fast acquisition or refreshment rate so I would like to find the simplest way to do it, codewize.

I found this example for 3D plotting (https://demo.bokehplots.com/apps/surface3d). Is it the best solution or is there a simpler way that do not require to create a server?

Thanks a lot,

Fabien

Hi,

Is there a reason you specifically mention the surface3d example? Do you require 3d plots? There is no 3d capability built into Bokeh, so that example is mostly about how Bokeh can be extended. However the JavaScript library that example uses for 3d is a toy library, in my opinion. If you really need 3d plots I'd say you'd probably want to find a better JS library to wrap as an extension.

Otherwise, this question is completely orthogonal to that example. Depending on your needs you can either embed server apps in notebooks (transparently/easily) or using push_notebook might be an option as well. You can find example notebooks for both approaches:

  https://github.com/bokeh/bokeh/tree/master/examples/howto/notebook_comms

  https://github.com/bokeh/bokeh/blob/master/examples/howto/server_embed/notebook_embed.ipynb

Thanks,

Bryan

···

On Feb 23, 2018, at 02:48, Fabien Lafont <[email protected]> wrote:

Dear all,

I am completely new to Bokeh and I would like to create a live plot. Baically I am controlling electronic instruments that send me some data let's say every few seconds that I would like to display. I would like to be able to interract with the graph (zooming for example) without disrupting the data acquisition. I don't need super fast acquisition or refreshment rate so I would like to find the simplest way to do it, codewize.
I found this example for 3D plotting (https://demo.bokehplots.com/apps/surface3d\). Is it the best solution or is there a simpler way that do not require to create a server?

Thanks a lot,

Fabien

--
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/7d8ae823-bc56-4490-b80e-eb446f626fee%40continuum.io\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.

Hello,

sorry about the long delay. I was indeed looking apparently at the wrong example. I managed to use the push_notebook to update a simple plot (see code bellow). It works fine for me for such plot but I would like to do it with a “color plot” (a 2D numpy array) where each time that I have an array of 10000 points it updates one slice of my image by putting the height as a color. Do you know if it is possible to do such things with bokeh or I need to generate each time a new image and send it to the figure? Would holoviews work better?

Thanks a lot.

from bokeh.io import push_notebook, show, output_notebook

from bokeh.layouts import row

from bokeh.plotting import figure

from random import randint

import time;

import numpy as np

output_notebook()

p1= figure(plot_width=450,plot_height=450)

x=[0]

y=[0]

r1=p1.line(x,y,line_width = 2)

t=show(p1,notebook_handle=True)

x=[0]

y=[0]

for i in range(5):

x = np.linspace(0,10000,10000)

y= np.random.rand(10000)

r1=p1.line(x,y,line_width = 2)

time.sleep(3.0)

push_notebook(handle=t)

···

On Mon, Feb 26, 2018 at 9:35 PM, Bryan Van de ven [email protected] wrote:

Hi,

Is there a reason you specifically mention the surface3d example? Do you require 3d plots? There is no 3d capability built into Bokeh, so that example is mostly about how Bokeh can be extended. However the JavaScript library that example uses for 3d is a toy library, in my opinion. If you really need 3d plots I’d say you’d probably want to find a better JS library to wrap as an extension.

Otherwise, this question is completely orthogonal to that example. Depending on your needs you can either embed server apps in notebooks (transparently/easily) or using push_notebook might be an option as well. You can find example notebooks for both approaches:

    [https://github.com/bokeh/bokeh/tree/master/examples/howto/notebook_comms](https://github.com/bokeh/bokeh/tree/master/examples/howto/notebook_comms)



    [https://github.com/bokeh/bokeh/blob/master/examples/howto/server_embed/notebook_embed.ipynb](https://github.com/bokeh/bokeh/blob/master/examples/howto/server_embed/notebook_embed.ipynb)

Thanks,

Bryan

On Feb 23, 2018, at 02:48, Fabien Lafont [email protected] wrote:

Dear all,

I am completely new to Bokeh and I would like to create a live plot. Baically I am controlling electronic instruments that send me some data let’s say every few seconds that I would like to display. I would like to be able to interract with the graph (zooming for example) without disrupting the data acquisition. I don’t need super fast acquisition or refreshment rate so I would like to find the simplest way to do it, codewize.

I found this example for 3D plotting (https://demo.bokehplots.com/apps/surface3d). Is it the best solution or is there a simpler way that do not require to create a server?

Thanks a lot,

Fabien

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/7d8ae823-bc56-4490-b80e-eb446f626fee%40continuum.io.

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

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/C251A8B1-631A-45A7-A24B-A6165B3977D6%40anaconda.com.
For more options, visit https://groups.google.com/a/continuum.io/d/optout.

Hi,

The push_notebook function uses the same protocol as the Bokeh sever, and e.g. the Bokeh server image_blur.py example under examples/app uses a slider to trigger an update of a 512x512 image interactively. And I have updates 1000x1000 image elsewhere. So if your total image size is 10k I would not expect any problems. If actually you mean a 10000x10000 sized image (it's not clear) then that will be too big.

Thanks,

Bryan

···

On Apr 17, 2018, at 11:52, Fabien Lafont <[email protected]> wrote:

Hello,

sorry about the long delay. I was indeed looking apparently at the wrong example. I managed to use the push_notebook to update a simple plot (see code bellow). It works fine for me for such plot but I would like to do it with a "color plot" (a 2D numpy array) where each time that I have an array of 10000 points it updates one slice of my image by putting the height as a color. Do you know if it is possible to do such things with bokeh or I need to generate each time a new image and send it to the figure? Would holoviews work better?

Thanks a lot.

from bokeh.io import push_notebook, show, output_notebook
from bokeh.layouts import row
from bokeh.plotting import figure
from random import randint
import time;
import numpy as np

output_notebook()

p1= figure(plot_width=450,plot_height=450)
x=[0]
y=[0]
r1=p1.line(x,y,line_width = 2)
t=show(p1,notebook_handle=True)

x=[0]
y=[0]
for i in range(5):
    x = np.linspace(0,10000,10000)
    y= np.random.rand(10000)

    r1=p1.line(x,y,line_width = 2)
    time.sleep(3.0)
    push_notebook(handle=t)

On Mon, Feb 26, 2018 at 9:35 PM, Bryan Van de ven <[email protected]> wrote:
Hi,

Is there a reason you specifically mention the surface3d example? Do you require 3d plots? There is no 3d capability built into Bokeh, so that example is mostly about how Bokeh can be extended. However the JavaScript library that example uses for 3d is a toy library, in my opinion. If you really need 3d plots I'd say you'd probably want to find a better JS library to wrap as an extension.

Otherwise, this question is completely orthogonal to that example. Depending on your needs you can either embed server apps in notebooks (transparently/easily) or using push_notebook might be an option as well. You can find example notebooks for both approaches:

        https://github.com/bokeh/bokeh/tree/master/examples/howto/notebook_comms

        https://github.com/bokeh/bokeh/blob/master/examples/howto/server_embed/notebook_embed.ipynb

Thanks,

Bryan

> On Feb 23, 2018, at 02:48, Fabien Lafont <[email protected]> wrote:
>
> Dear all,
>
> I am completely new to Bokeh and I would like to create a live plot. Baically I am controlling electronic instruments that send me some data let's say every few seconds that I would like to display. I would like to be able to interract with the graph (zooming for example) without disrupting the data acquisition. I don't need super fast acquisition or refreshment rate so I would like to find the simplest way to do it, codewize.
> I found this example for 3D plotting (https://demo.bokehplots.com/apps/surface3d\). Is it the best solution or is there a simpler way that do not require to create a server?
>
> Thanks a lot,
>
> Fabien
>
> --
> 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/7d8ae823-bc56-4490-b80e-eb446f626fee%40continuum.io\.
> For more options, visit https://groups.google.com/a/continuum.io/d/optout\.

--
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/C251A8B1-631A-45A7-A24B-A6165B3977D6%40anaconda.com\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.

--
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/CAC9H_ch7uXb9MpupU2tDqyhFo3V%3DUUcC%2BtewG%2B9iVmqsXmq7_Q%40mail.gmail.com\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.

Hi thanks a lot.

In fact I have a little problem (that I didn’t notice previously). In the sample code presented bellow each time that the push notebook is called it replot all the curve on top of the previous one (we can clearly see it from the evolution of the color of the line). How can I simply ask it to add the datapoints to the previous one without replotting everything?

Thanks!

from bokeh.io import push_notebook, show, output_notebook

from bokeh.plotting import figure

from random import randint

import time

import numpy as np

output_notebook()

p1= figure(plot_width=450,plot_height=450)

x=

y=

r1=p1.line(x,y,line_width = 2, alpha=1)

t=show(p1,notebook_handle=True)

for i in range(0,500):

x = np.append(x,i)

y= np.append(y,randint(0,12))

r1=p1.line(x,y,line_width = 2, alpha=0.2)

time.sleep(0.2)

push_notebook(handle=t)

···

On Tue, Apr 17, 2018 at 9:09 PM Bryan Van de ven [email protected] wrote:

Hi,

The push_notebook function uses the same protocol as the Bokeh sever, and e.g. the Bokeh server image_blur.py example under examples/app uses a slider to trigger an update of a 512x512 image interactively. And I have updates 1000x1000 image elsewhere. So if your total image size is 10k I would not expect any problems. If actually you mean a 10000x10000 sized image (it’s not clear) then that will be too big.

Thanks,

Bryan

On Apr 17, 2018, at 11:52, Fabien Lafont [email protected] wrote:

Hello,

sorry about the long delay. I was indeed looking apparently at the wrong example. I managed to use the push_notebook to update a simple plot (see code bellow). It works fine for me for such plot but I would like to do it with a “color plot” (a 2D numpy array) where each time that I have an array of 10000 points it updates one slice of my image by putting the height as a color. Do you know if it is possible to do such things with bokeh or I need to generate each time a new image and send it to the figure? Would holoviews work better?

Thanks a lot.

from bokeh.io import push_notebook, show, output_notebook

from bokeh.layouts import row

from bokeh.plotting import figure

from random import randint

import time;

import numpy as np

output_notebook()

p1= figure(plot_width=450,plot_height=450)

x=[0]

y=[0]

r1=p1.line(x,y,line_width = 2)

t=show(p1,notebook_handle=True)

x=[0]

y=[0]

for i in range(5):

x = np.linspace(0,10000,10000)
y= np.random.rand(10000)
r1=p1.line(x,y,line_width = 2)
time.sleep(3.0)
push_notebook(handle=t)

On Mon, Feb 26, 2018 at 9:35 PM, Bryan Van de ven [email protected] wrote:

Hi,

Is there a reason you specifically mention the surface3d example? Do you require 3d plots? There is no 3d capability built into Bokeh, so that example is mostly about how Bokeh can be extended. However the JavaScript library that example uses for 3d is a toy library, in my opinion. If you really need 3d plots I’d say you’d probably want to find a better JS library to wrap as an extension.

Otherwise, this question is completely orthogonal to that example. Depending on your needs you can either embed server apps in notebooks (transparently/easily) or using push_notebook might be an option as well. You can find example notebooks for both approaches:

    [https://github.com/bokeh/bokeh/tree/master/examples/howto/notebook_comms](https://github.com/bokeh/bokeh/tree/master/examples/howto/notebook_comms)
    [https://github.com/bokeh/bokeh/blob/master/examples/howto/server_embed/notebook_embed.ipynb](https://github.com/bokeh/bokeh/blob/master/examples/howto/server_embed/notebook_embed.ipynb)

Thanks,

Bryan

On Feb 23, 2018, at 02:48, Fabien Lafont [email protected] wrote:

Dear all,

I am completely new to Bokeh and I would like to create a live plot. Baically I am controlling electronic instruments that send me some data let’s say every few seconds that I would like to display. I would like to be able to interract with the graph (zooming for example) without disrupting the data acquisition. I don’t need super fast acquisition or refreshment rate so I would like to find the simplest way to do it, codewize.

I found this example for 3D plotting (https://demo.bokehplots.com/apps/surface3d). Is it the best solution or is there a simpler way that do not require to create a server?

Thanks a lot,

Fabien

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/7d8ae823-bc56-4490-b80e-eb446f626fee%40continuum.io.

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

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/C251A8B1-631A-45A7-A24B-A6165B3977D6%40anaconda.com.

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

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/CAC9H_ch7uXb9MpupU2tDqyhFo3V%3DUUcC%2BtewG%2B9iVmqsXmq7_Q%40mail.gmail.com.

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

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/9B9E4241-8BD9-457D-A204-3326BA5BC9FA%40anaconda.com.

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

Hi. Did you solve this? Having the same problem…

···

On Friday, May 4, 2018 at 9:18:40 AM UTC+1, Fabien Lafont wrote:

Hi thanks a lot.

In fact I have a little problem (that I didn’t notice previously). In the sample code presented bellow each time that the push notebook is called it replot all the curve on top of the previous one (we can clearly see it from the evolution of the color of the line). How can I simply ask it to add the datapoints to the previous one without replotting everything?

Thanks!

from bokeh.io import push_notebook, show, output_notebook

from bokeh.plotting import figure

from random import randint

import time

import numpy as np

output_notebook()

p1= figure(plot_width=450,plot_height=450)

x=

y=

r1=p1.line(x,y,line_width = 2, alpha=1)

t=show(p1,notebook_handle=True)

for i in range(0,500):

x = np.append(x,i)

y= np.append(y,randint(0,12))

r1=p1.line(x,y,line_width = 2, alpha=0.2)

time.sleep(0.2)

push_notebook(handle=t)

On Tue, Apr 17, 2018 at 9:09 PM Bryan Van de ven [email protected] wrote:

Hi,

The push_notebook function uses the same protocol as the Bokeh sever, and e.g. the Bokeh server image_blur.py example under examples/app uses a slider to trigger an update of a 512x512 image interactively. And I have updates 1000x1000 image elsewhere. So if your total image size is 10k I would not expect any problems. If actually you mean a 10000x10000 sized image (it’s not clear) then that will be too big.

Thanks,

Bryan

On Apr 17, 2018, at 11:52, Fabien Lafont [email protected] wrote:

Hello,

sorry about the long delay. I was indeed looking apparently at the wrong example. I managed to use the push_notebook to update a simple plot (see code bellow). It works fine for me for such plot but I would like to do it with a “color plot” (a 2D numpy array) where each time that I have an array of 10000 points it updates one slice of my image by putting the height as a color. Do you know if it is possible to do such things with bokeh or I need to generate each time a new image and send it to the figure? Would holoviews work better?

Thanks a lot.

from bokeh.io import push_notebook, show, output_notebook

from bokeh.layouts import row

from bokeh.plotting import figure

from random import randint

import time;

import numpy as np

output_notebook()

p1= figure(plot_width=450,plot_height=450)

x=[0]

y=[0]

r1=p1.line(x,y,line_width = 2)

t=show(p1,notebook_handle=True)

x=[0]

y=[0]

for i in range(5):

x = np.linspace(0,10000,10000)
y= np.random.rand(10000)
r1=p1.line(x,y,line_width = 2)
time.sleep(3.0)
push_notebook(handle=t)

On Mon, Feb 26, 2018 at 9:35 PM, Bryan Van de ven [email protected] wrote:

Hi,

Is there a reason you specifically mention the surface3d example? Do you require 3d plots? There is no 3d capability built into Bokeh, so that example is mostly about how Bokeh can be extended. However the JavaScript library that example uses for 3d is a toy library, in my opinion. If you really need 3d plots I’d say you’d probably want to find a better JS library to wrap as an extension.

Otherwise, this question is completely orthogonal to that example. Depending on your needs you can either embed server apps in notebooks (transparently/easily) or using push_notebook might be an option as well. You can find example notebooks for both approaches:

    [https://github.com/bokeh/bokeh/tree/master/examples/howto/notebook_comms](https://github.com/bokeh/bokeh/tree/master/examples/howto/notebook_comms)
    [https://github.com/bokeh/bokeh/blob/master/examples/howto/server_embed/notebook_embed.ipynb](https://github.com/bokeh/bokeh/blob/master/examples/howto/server_embed/notebook_embed.ipynb)

Thanks,

Bryan

On Feb 23, 2018, at 02:48, Fabien Lafont [email protected] wrote:

Dear all,

I am completely new to Bokeh and I would like to create a live plot. Baically I am controlling electronic instruments that send me some data let’s say every few seconds that I would like to display. I would like to be able to interract with the graph (zooming for example) without disrupting the data acquisition. I don’t need super fast acquisition or refreshment rate so I would like to find the simplest way to do it, codewize.

I found this example for 3D plotting (https://demo.bokehplots.com/apps/surface3d). Is it the best solution or is there a simpler way that do not require to create a server?

Thanks a lot,

Fabien

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/7d8ae823-bc56-4490-b80e-eb446f626fee%40continuum.io.

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

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/C251A8B1-631A-45A7-A24B-A6165B3977D6%40anaconda.com.

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

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/CAC9H_ch7uXb9MpupU2tDqyhFo3V%3DUUcC%2BtewG%2B9iVmqsXmq7_Q%40mail.gmail.com.

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

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/9B9E4241-8BD9-457D-A204-3326BA5BC9FA%40anaconda.com.

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

Hi,

There was previously an issue with adding new glyphs after calling push_notebook. I believe that has been resolved, however, I would say that is not a good approach in any case. You should add the glyph to start, then use push_notebook to update the *data source* for the glyph. There is usually never need to add new glyphs.

Thanks,

Bryan

···

On Sep 13, 2018, at 11:16, [email protected] wrote:

Hi. Did you solve this? Having the same problem...

On Friday, May 4, 2018 at 9:18:40 AM UTC+1, Fabien Lafont wrote:
Hi thanks a lot.

In fact I have a little problem (that I didn't notice previously). In the sample code presented bellow each time that the push notebook is called it replot all the curve on top of the previous one (we can clearly see it from the evolution of the color of the line). How can I simply ask it to add the datapoints to the previous one without replotting everything?

Thanks!

from bokeh.io import push_notebook, show, output_notebook
from bokeh.plotting import figure
from random import randint
import time
import numpy as np

output_notebook()

p1= figure(plot_width=450,plot_height=450)
x=
y=

r1=p1.line(x,y,line_width = 2, alpha=1)
t=show(p1,notebook_handle=True)

for i in range(0,500):
    x = np.append(x,i)
    y= np.append(y,randint(0,12))
    r1=p1.line(x,y,line_width = 2, alpha=0.2)
    time.sleep(0.2)
    push_notebook(handle=t)

On Tue, Apr 17, 2018 at 9:09 PM Bryan Van de ven <[email protected]> wrote:
Hi,

The push_notebook function uses the same protocol as the Bokeh sever, and e.g. the Bokeh server image_blur.py example under examples/app uses a slider to trigger an update of a 512x512 image interactively. And I have updates 1000x1000 image elsewhere. So if your total image size is 10k I would not expect any problems. If actually you mean a 10000x10000 sized image (it's not clear) then that will be too big.

Thanks,

Bryan

> On Apr 17, 2018, at 11:52, Fabien Lafont <[email protected]> wrote:
>
> Hello,
>
> sorry about the long delay. I was indeed looking apparently at the wrong example. I managed to use the push_notebook to update a simple plot (see code bellow). It works fine for me for such plot but I would like to do it with a "color plot" (a 2D numpy array) where each time that I have an array of 10000 points it updates one slice of my image by putting the height as a color. Do you know if it is possible to do such things with bokeh or I need to generate each time a new image and send it to the figure? Would holoviews work better?
>
> Thanks a lot.
>
>
> from bokeh.io import push_notebook, show, output_notebook
> from bokeh.layouts import row
> from bokeh.plotting import figure
> from random import randint
> import time;
> import numpy as np
>
> output_notebook()
>
>
>
> p1= figure(plot_width=450,plot_height=450)
> x=[0]
> y=[0]
> r1=p1.line(x,y,line_width = 2)
> t=show(p1,notebook_handle=True)
>
>
>
>
> x=[0]
> y=[0]
> for i in range(5):
> x = np.linspace(0,10000,10000)
> y= np.random.rand(10000)
>
>
> r1=p1.line(x,y,line_width = 2)
> time.sleep(3.0)
> push_notebook(handle=t)
>
>
> On Mon, Feb 26, 2018 at 9:35 PM, Bryan Van de ven <[email protected]> wrote:
> Hi,
>
> Is there a reason you specifically mention the surface3d example? Do you require 3d plots? There is no 3d capability built into Bokeh, so that example is mostly about how Bokeh can be extended. However the JavaScript library that example uses for 3d is a toy library, in my opinion. If you really need 3d plots I'd say you'd probably want to find a better JS library to wrap as an extension.
>
> Otherwise, this question is completely orthogonal to that example. Depending on your needs you can either embed server apps in notebooks (transparently/easily) or using push_notebook might be an option as well. You can find example notebooks for both approaches:
>
> https://github.com/bokeh/bokeh/tree/master/examples/howto/notebook_comms
>
> https://github.com/bokeh/bokeh/blob/master/examples/howto/server_embed/notebook_embed.ipynb
>
> Thanks,
>
> Bryan
>
> > On Feb 23, 2018, at 02:48, Fabien Lafont <[email protected]> wrote:
> >
> > Dear all,
> >
> > I am completely new to Bokeh and I would like to create a live plot. Baically I am controlling electronic instruments that send me some data let's say every few seconds that I would like to display. I would like to be able to interract with the graph (zooming for example) without disrupting the data acquisition. I don't need super fast acquisition or refreshment rate so I would like to find the simplest way to do it, codewize.
> > I found this example for 3D plotting (https://demo.bokehplots.com/apps/surface3d\). Is it the best solution or is there a simpler way that do not require to create a server?
> >
> > Thanks a lot,
> >
> > Fabien
> >
> > --
> > 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/7d8ae823-bc56-4490-b80e-eb446f626fee%40continuum.io\.
> > For more options, visit https://groups.google.com/a/continuum.io/d/optout\.
>
> --
> 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/C251A8B1-631A-45A7-A24B-A6165B3977D6%40anaconda.com\.
> For more options, visit https://groups.google.com/a/continuum.io/d/optout\.
>
>
> --
> 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/CAC9H_ch7uXb9MpupU2tDqyhFo3V%3DUUcC%2BtewG%2B9iVmqsXmq7_Q%40mail.gmail.com\.
> For more options, visit https://groups.google.com/a/continuum.io/d/optout\.

--
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/9B9E4241-8BD9-457D-A204-3326BA5BC9FA%40anaconda.com\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.

--
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/5f97a71a-0207-406b-9881-8d34042cc264%40continuum.io\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.