jtromans
jtromans

Reputation: 4263

NVD3 JavaScript charting - lineChart with duplicate right hand y-axis using 1 or more series

I have been unable to discover how to add a second, identical, y-axis on the right side of the chart. As a side issue, I don't know how to switch which side the y-axis is on. Period.

I have looked into the multiChart type, but it seems as though a data series must be assigned to a specific axis; if I only have one series, the second axis does not show. I have thought about assigning the same series to both axis by duplicating the series, but this is terrible work around.

What is the correct solution to achieve two identical y-axis on both the left and right sides of the lineChart, when using one (or more) series?

Upvotes: 1

Views: 301

Answers (1)

Lars Kotthoff
Lars Kotthoff

Reputation: 109242

You would have to modify the source code to do this -- NVD3 simply doesn't support this. Alternatively, you could add the second axis manually.

Upvotes: 1

Related Questions