ipython-books / cookbook-code

[DEPRECATED] See the new edition:
http://ipython-books.github.io/
Other
975 stars 454 forks source link

bokeh API changed #21

Closed jimofthecorn closed 9 years ago

jimofthecorn commented 9 years ago

I've just installed bokeh 0.8.2 (the version pip finds). The 'line' and 'scatter' functions are now methods of a figure object, so in notebook chapter06/03_bokeh I had to change the first example to:

p = bkh.figure(title="random data", x_axis_label='x', y_axis_label='y') p.line(x, y, line_width=5) bkh.show(p)

and the second to:

p = bkh.figure(title="flower petal shapes by color", x_axis_label='petal_length', y_axis_label='petal_width') p.scatter(flowers["petal_length"], flowers["petal_width"], color=flowers["color"], fill_alpha=0.25, size=10,) bkh.show(p)

rossant commented 9 years ago

Thanks! I'll update it as soon I have some time, unless you beat me to it with a pull request ;)

j9ac9k commented 9 years ago

I just ran into this issue, I'll try and hammer out a corrected notebook and then submit a PR.

j9ac9k commented 9 years ago

Generated PR #22 which compensates for changes in bokeh api

rossant commented 9 years ago

closed by #22