Home › forums › Using CanvasJS › Customize shaded area direction in Area Chart
Tagged: Area Chart Shaded Area direction
This topic contains 6 replies, has 2 voices, and was last updated by cancanvas 1 year, 10 months ago.
I want to fill areas under the data points always using area chart. However, when data points are negative, canvasJS fill the area above the datapoint by default. Any suggestions?
Please take a look at this jsfiddle.
Thanks for the quick response. However, what I need is to shade the area between the line serie and x-axis instead of x=0 line.
Please provide a pictorial representation of your requirement so that we can understand your problem better and help you accordingly.
This forum does not allow me to attach an image. I am not able to provide pictural presentation.
Basically, I want the area chart always shade the area below the line. In currently implementation of your area chart, you shade the area above the line if the value is negative. I want to shade the area below the chart even though the value is negative. Is it doable? Thanks a lot!
You can use rangeArea chart instead of area chart to show filled area even for negative dataPoints as a work-around. Please take a look at this jsfiddle.
Thank you Indranil. This is all I need!
You must be logged in to reply to this topic.