|
Static area around line |
Posted by Yorick B on Apr-28-2011 22:48 |
|
Hi,
I have been looking at standard deviation related posts, but can't find anything describing something similar to mine.
I want to show a certain area around my linelayer within a XYChart. I have a method calculating the standard deviation over an array of percentages, and now i want to make sure that, for example an standard deviation of 4.4, is shown as an area around my linelayer. Just the way as for example a confidence band does this, but i read that this band is already based on a mathmetical concept.
Is there a method within chart director which makes it possible to easily add the standard deviation information? or is there some kind of band/area, which can be defined relatively to a linelayer?
I hope you understand my problem. Already thanks for the effort |
Re: Static area around line |
Posted by Peter Kwan on Apr-29-2011 01:17 |
|
Hi Yorick,
I am not too sure what is "a standard deviation of 4.4" mean to a line. If you want to you mean to plot a zone, which extends +/- 4.4 unit vertically above and below the line, you can use the following method:
(a) Draw a line layer, using data points that are 4.4 above your original data points.
(b) Draw another line layer, using data points that are 4.4 below your original data points.
(c) Use an interline layer (XYChart.addInterLineLayer) to fill the region in between two lines in (a) and (b).
You may refer to the sample code "X Zone Coloring" for an example.
Hope this can help.
Regards
Peter Kwan |
|