Home forums Feature Requests & Feedback Aligning Multiple Vertical Charts

This topic contains 7 replies, has 3 voices, and was last updated by  Sanjoy 5 months, 3 weeks ago.

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #10581

    arcticio
    Member

    I have three charts and all share the same x axis data, but different Y data. The charts would look extremely better, if it’s possible to somehow vertically align the y axes, so the upper 2 X axes could be dropped. I’d propose to allow to give a fixed margin on either side.

    • This topic was modified 6 months, 1 week ago by  arcticio.
    #10583

    Sanjoy
    Moderator

    Arcticio,

    Thanks for your feed-back. Are you looking for axisY/Y2 margin?

    #11281

    arcticio
    Member

    I tried, but it somehow depends on the axes labels. Here I put all six to 160px to illustrate.

    • This reply was modified 6 months ago by  arcticio.
    #11285

    Sanjoy
    Moderator

    Arcticio,

    As of now the exact same feature is not available. You have to do little manipulation using labelMaxWidth and margin of axis.

    #11356

    Is this feature on the CanvasJS backlog?
    I also have the same problem. I want to have two vertically aligned charts and have the same width of the chart area for both.

    Intended behaviour

    As you can see the width of the chart area for both are the same.

    But with CanvasJS I only managed to create this:

    Current (wrong) behaviour

    Is there a way (with the current version) of recreating the first behaviour?

    #11361

    Sanjoy
    Moderator

    Hi,

    As of now this feature is not available in our library. Here is an workaround to align the axis.

    #11362

    My use case is for the Y-Axis to be on the right side, for the left side your solution works perfectly, is it possible to do it if the Y-Axis is on the right?

    #11363

    Sanjoy
    Moderator

    You can do the same for axisY2. Here is updated fiddle with aligning axisY2.

Viewing 8 posts - 1 through 8 (of 8 total)

You must be logged in to reply to this topic.