Line chart: second x- and y- axis possible?

Hello,

I could not find something about this in the documentation: Is there an option to set second axis’ x2 and y2 for Line charts (from bokeh.charts)?

Thanks

Daniel

Hi Daniel,

The bokeh.charts functions are really just conveniences that produce the same low-level objects that bokeh.plotting does (or building everything from scratch with bokeh.models does). So I think adding a second axis would not look much different than this bokeh.plotting example:

  https://github.com/bokeh/bokeh/blob/master/examples/plotting/file/twin_axis.py

In particular I think this would be identical:

  my_chart.extra_y_ranges['foo'] = Range1d(0, 100)
  my_chart.add_layout(LinearAxis(y_range_name="foo"), 'left')

But I do not have time to test this out, so please let us know if this works as expected or not.

Bryan

···

On Apr 19, 2016, at 2:30 PM, 'Daniel Krause' via Bokeh Discussion - Public <[email protected]> wrote:

Hello,

I could not find something about this in the documentation: Is there an option to set second axis' x2 and y2 for Line charts (from bokeh.charts)?

Thanks
Daniel

--
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/cf41e1e3-df65-4dc6-b6fd-7ca00af7f55c%40continuum.io\.
For more options, visit https://groups.google.com/a/continuum.io/d/optout\.

Hi Bryan,

yes, the linked example and your comment are exactly working as needed.

Thanks

Daniel

···

Am Dienstag, 19. April 2016 23:08:53 UTC+2 schrieb Bryan Van de ven:

Hi Daniel,

The bokeh.charts functions are really just conveniences that produce the same low-level objects that bokeh.plotting does (or building everything from scratch with bokeh.models does). So I think adding a second axis would not look much different than this bokeh.plotting example:

    [https://github.com/bokeh/bokeh/blob/master/examples/plotting/file/twin_axis.py](https://github.com/bokeh/bokeh/blob/master/examples/plotting/file/twin_axis.py)

In particular I think this would be identical:

    my_chart.extra_y_ranges['foo'] = Range1d(0, 100)

    my_chart.add_layout(LinearAxis(y_range_name="foo"), 'left')

But I do not have time to test this out, so please let us know if this works as expected or not.

Bryan

On Apr 19, 2016, at 2:30 PM, ‘Daniel Krause’ via Bokeh Discussion - Public [email protected] wrote:

Hello,

I could not find something about this in the documentation: Is there an option to set second axis’ x2 and y2 for Line charts (from bokeh.charts)?

Thanks

Daniel


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/cf41e1e3-df65-4dc6-b6fd-7ca00af7f55c%40continuum.io.

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