Chart is not showing the data (source.data) is updated

Hi everyone,

I hope you can help me. Ma chart is not changing even if I am pushing new Data into the ColumnDataSource.

from bokeh.layouts import column

from bokeh.models import Button

from bokeh.plotting import figure, curdoc

from bokeh.models import ColumnDataSource

from sklearn.externals import joblib

def callback():

sys_probas.data = dict(

x = [1,2],y=[0.2,0.8]

)

sys_probas = ColumnDataSource(data=dict(x=, y=))

p = figure(plot_height=300, plot_width=600, x_range = [0,3], y_range = [0,1],

		title="Scores")

p.vbar(x=“x”, top = “y”, source = sys_probas.data, width=0.5, bottom=0)

val = Button(label=“HELP ME !”)

val.on_click(callback)

curdoc().add_root(column(val,p))

``

Does anyone has an idea?

The data values are updated but the graph only take the first values I give to it.

Thank you in advance

__This message and any attachments is intended for the named addressee(s) only and may contain information that is privileged and/or confidential. If you receive this message in error, please delete it and immediately notify the sender. Any copying, dissemination or disclosure, either whole or partial, by a person who is not the named addressee is prohibited. We use virus scanning software but disclaim any liability for viruses or other devices which remain in this message or any attachments.

···

Ce message, ainsi que toute piece jointe, est exclusivement adresse au(x) destinataire(s) nomme(s) et peut contenir des informations confidentielles. Si vous recevez ce message par erreur, merci de le detruire et d’en avertir immediatement l’emetteur. Toute copie, transmission ou divulgation, integrale ou partielle, par une personne qui n’est pas nommee comme destinataire est interdite. Nous utilisons un logiciel anti-virus mais nous denions toute responsabilite au cas ou des virus, ou tout autre procede, seraient contenus dans ce message ou toute piece jointe.__

The value of source should be the ColumnDataSource (i.e. sys_probas) not the .data property of the CDS (i.e. not sys_probas.data)

Thanks,

Bryan

···

On Jun 7, 2017, at 05:05, [email protected] wrote:

Hi everyone,

I hope you can help me. Ma chart is not changing even if I am pushing new Data into the ColumnDataSource.

from bokeh.layouts import column
from bokeh.models import Button
from bokeh.plotting import figure, curdoc
from bokeh.models import ColumnDataSource

from sklearn.externals import joblib

def callback():
  sys_probas.data = dict(
        x = [1,2],y=[0.2,0.8]
    )

sys_probas = ColumnDataSource(data=dict(x=, y=))

p = figure(plot_height=300, plot_width=600, x_range = [0,3], y_range = [0,1],
      title="Scores")

p.vbar(x="x", top = "y", source = sys_probas.data, width=0.5, bottom=0)

val = Button(label="HELP ME !")
val.on_click(callback)

curdoc().add_root(column(val,p))

Does anyone has an idea?

The data values are updated but the graph only take the first values I give to it.

Thank you in advance

This message and any attachments is intended for the named addressee(s) only and may contain information that is privileged and/or confidential. If you receive this message in error, please delete it and immediately notify the sender. Any copying, dissemination or disclosure, either whole or partial, by a person who is not the named addressee is prohibited. We use virus scanning software but disclaim any liability for viruses or other devices which remain in this message or any attachments.
*******************************
Ce message, ainsi que toute piece jointe, est exclusivement adresse au(x) destinataire(s) nomme(s) et peut contenir des informations confidentielles. Si vous recevez ce message par erreur, merci de le detruire et d'en avertir immediatement l'emetteur. Toute copie, transmission ou divulgation, integrale ou partielle, par une personne qui n'est pas nommee comme destinataire est interdite. Nous utilisons un logiciel anti-virus mais nous denions toute responsabilite au cas ou des virus, ou tout autre procede, seraient contenus dans ce message ou toute piece jointe.

--
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/3ba2fd8c-8354-4d50-8399-b440c5d1bb7b%40continuum.io\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.