ASE Home Page Products Download Purchase Support About ASE
ChartDirector Support
Forum HomeForum Home   SearchSearch

Message ListMessage List     Post MessagePost Message

  Gaps in area charts
Posted by L on Mar-08-2012 05:07
Hello,

I have a quick question about area layers.  I'm filling my data series with values and sending
the Chart.NoValue constant for any missing values.  Currently, I'm setting the gap color on
the layer to be a semitransparent gray and the area chart fill color to be blue.  This all
works great.  We have a request to draw discontinuous area charts when there is missing
data, instead of the gray gap color.  So I've looked into changing the gap color to a
transparent white (background color), but I believe the data line (currently blue) will always
be visible, unless I were to change the data line color to be the same as the background
color also.  I don't love that idea, because it sort of misrepresents the height of the data,
even if only slightly.  I was wondering if you knew of any other way to make the area chart
look discontinuous where there are gaps.  I am trying to avoid chopping my data arrays up
and creating separate area layers because it's a significant performance hit.

Thanks!
L

  Re: Gaps in area charts
Posted by Peter Kwan on Mar-09-2012 01:01
Hi L,

You can set the border color to Chart.SameAsMainColor. In this way, the border will be of the same color as the area fill color, and will have a gap if the filled region has a gap. Also, the height will not be misrepresented.

If you prefer the border to have a different color from the area filled region, but still have a  gap, you may still use Chart.SameAsMainColor or even Chart.Transparent as the border color. You may add an additional line layer before the area layer (so it says on top of the area layer) using the same data for the actual border. The line layer by default will have a gap at NoValue positions. You can also configured a different gap color for the line (such as using a dashed line color or dotted line color).

Hope this can help.

Regards
Peter Kwan