TiPlotChannelCustom.AddXYArray
TiPlotChannelCustom
procedure AddXYArray(XData: Variant);
Description
Adds data to a channel a single, two dimensional array. The first dimension
of the array is the X-coordinate data. The second dimension of the array is the
Y-coordinate data. The number of elements in each dimension must be identical
(i.e. if the first dimension contains 100 elements, the second dimension must
contain 100 elements), otherwise an exception will be generated.
This procedure is able to handle variant arrays that start at element 0 or any
value that you require. If you array starts at element 1, then that value
will be used to add the first data point.
Note: it is recommended that you loop through your array and use the AddXY method to add data to the chart as that is much faster than using the
AddXYArrays procedure due to the use of Variants. This procedure has been added as a
convenient way of passing arrays to the channel to add data, but is slower than
simply looping through the array in your program.
Note: If your data is already in Variant array format (i.e. not a double array),
then there is no performance penalty by using the AddXYArrays procedure.
Example
Delphi
iComponent.Channel[0].AddXYArray(TwoDimensionalDataArray);
C++ Builder
iComponent->Channel[0]->AddXYArray(TwoDimensionalDataArray);
Contents | Index | Previous | Next