DrawAllPoints false does not plot narrow data spikes

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
SteveP
Advanced
Posts: 132
Joined: Sun Sep 07, 2003 4:00 am

DrawAllPoints false does not plot narrow data spikes

Post by SteveP » Fri Dec 17, 2004 2:19 pm

Setting DrawAllPoints false produces plots that often do not display data points that are narrow spikes in FastLineSeries.

For example, generate 20,000 points of random values as in
Y[0]:=Random(10000);
for t := 1 to Num-1 do Y[t]:=Y[t-1]+Random(101)-50;
which is the data function found in the "Real-time charting in TeeChart VCL" at
http://www.teechart.net/support/modules ... icle&sid=6
which also describes the behavior of the DrawAlPoints property.
Then set some single points to values far outside neighboring values such as :
y[123] := 0;
y[1234] := 0;
y[12345] := 0;

These 0 values are always displayed when DrawAllPoints is True. But they are only occasionally there when it is False.

Addionally, if the Chart Alignment is set to Client so that the chart resizes when the form is resized, then the appearance of these 0 point spikes with DrawAllPoints as false depends on the size of the chart. They will appear and disappear as the form and chart is resized.

These 0 points can be made to appear by increasing the width of the data region of 0 valued points, by for example:
for i := 1 to width do y[12345+i] := 0;

Steve

Thomas Klingler
Advanced
Posts: 103
Joined: Tue Mar 02, 2004 5:00 am
Location: Bad Wurzach
Contact:

Post by Thomas Klingler » Mon Dec 20, 2004 10:41 am

That's right. You didn't understand this concept. See help for DrawAllPoints:

"So, when the series has several points that share the same X pixel position, but with different Y position, it will only display the first point."

this implies:

"In some cases, setting DrawAllPoints can dramatically speed up displaying a FastLine series with lots lots of points.
But, as not all points are displayed, the final output might not be as accurated."

SteveP
Advanced
Posts: 132
Joined: Sun Sep 07, 2003 4:00 am

Post by SteveP » Mon Dec 20, 2004 2:18 pm

The link provided in my original question says the behavior is different from the Help you quote:

"...group the points with the same x screen pixel coordinate and replace them with two points (group minimum and maximum values). The end result will visually be the same as drawing all the points in the group"

This doesn't state whether it draws a vertical line segment between those group min and max points though, which is what it should do to have the display visually similar to drawing all points.

ungos
Newbie
Newbie
Posts: 12
Joined: Mon Oct 04, 2004 4:00 am
Location: Czech Republic
Contact:

Post by ungos » Mon Dec 20, 2004 4:17 pm

OK, in this article seems to be original (and more practical I think) idea of DrawAllPoins property. But reality is another thing. I've TeeChartPro7 VCL version and help file describes true realized behavior.

Post Reply