 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
m610 Guest
|
Posted: Thu Dec 07, 2006 9:12 am Post subject: Finding the series index for the data at the x-axis minimum |
|
|
I'd like to be able to determine which item in a lineseries is located
at/near the x-axis minimum (left y-axis) without having to search all
my data (some 40,000 point) to find a close match. My searching
procedure works OK, but it is clumbsy and a bit slow. I was hoping
that TeeChart had a handy property I could read instead.
Thanks in advance. |
|
| Back to top |
|
 |
David Berneda Guest
|
Posted: Thu Dec 07, 2006 10:40 pm Post subject: Re: Finding the series index for the data at the x-axis mini |
|
|
Hi
http://www.steema.net/TeeChart6Docs/TChartSeries.FirstValueIndex.html
When the line is displayed, the min and max indexes are internally calculated to avoid painting many points that might possible be
outside the chart rectangle.
These properties are available only *after* that chart has displayed.
var a,b : Integer;
a := Series1.FirstValueIndex;
b: =Series1.LastValueIndex;
They are "-1" meaning the whole series points ( from 0 to Series1.Count-1 ) need to be displayed.
With these indexes you can then query the series values:
var valueMin : Double;
valueMin := Series1.YValues[ a ];
regards
david
www.teechart.com
"m610" <mlmeier (AT) sbcglobal (DOT) net> wrote in message news:1165463322.790785.231110 (AT) n67g2000cwd (DOT) googlegroups.com...
| Quote: | I'd like to be able to determine which item in a lineseries is located
at/near the x-axis minimum (left y-axis) without having to search all
my data (some 40,000 point) to find a close match. My searching
procedure works OK, but it is clumbsy and a bit slow. I was hoping
that TeeChart had a handy property I could read instead.
Thanks in advance.
|
|
|
| Back to top |
|
 |
m610 Guest
|
Posted: Mon Dec 11, 2006 12:05 am Post subject: Re: Finding the series index for the data at the x-axis mini |
|
|
Thanks. It worked perfectly and everything is running smooth and quick
now.
Mike
David Berneda wrote:
| Quote: | Hi
http://www.steema.net/TeeChart6Docs/TChartSeries.FirstValueIndex.html
When the line is displayed, the min and max indexes are internally calculated to avoid painting many points that might possible be
outside the chart rectangle.
These properties are available only *after* that chart has displayed.
var a,b : Integer;
a := Series1.FirstValueIndex;
b: =Series1.LastValueIndex;
They are "-1" meaning the whole series points ( from 0 to Series1.Count-1 ) need to be displayed.
With these indexes you can then query the series values:
var valueMin : Double;
valueMin := Series1.YValues[ a ];
regards
david
www.teechart.com
"m610" <mlmeier (AT) sbcglobal (DOT) net> wrote in message news:1165463322.790785.231110 (AT) n67g2000cwd (DOT) googlegroups.com...
I'd like to be able to determine which item in a lineseries is located
at/near the x-axis minimum (left y-axis) without having to search all
my data (some 40,000 point) to find a close match. My searching
procedure works OK, but it is clumbsy and a bit slow. I was hoping
that TeeChart had a handy property I could read instead.
Thanks in advance.
|
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|