I’m looking for a JavaScript charting library that supports shading the area between two lines. ChartDirector handles this quite nicely (see: http://www.advsofteng.com/gallery_line2.html – Inter-line Coloring), but I require a more interactive charting library.
I’ve looked into various JavaScript libraries. Flot and Highcharts come close, but still have their limitations:
- Flot supports shading between two lines using the fillBetween plugin, but it does not support shading with multiple colors depending on which line is on top.
- One can achieve shading between two lines with Highcharts using stacked area charts, but it does not handle the case where the two lines intersect.
Any suggestions?
I ended up using Highcharts. I took this example ElementStacks and modified it to handle the intersections. See Negative Area.