ChartDirector 7.0 (Perl Edition)

SurfaceChart.setData


Usage

setData(xData, yData, zData [, wData ])

Description

Sets the data for the surface chart.

ChartDirector supports both gridded and scattered data. If the data points are on a rectangular grid will no missing points, they will be handled as gridded data. Otherwise, they will be handled as scattered data.

For gridded data, you may provide the x and y values of the grid, and the z values of the data points. For a 10 x 15 grid, that means the x data series should have 10 values, the y data series should have 15 values, and the z data series should have 150 values. The x and y data series should be strictly monotonic (either strictly increasing or strictly decreasing).

For both gridded and scattered data, you may also provide the (x, y, z) values of the data points. For example, for 150 data points, the x, y and z data series should each have 150 values. ChartDirector will automatically detect if the data points are gridded or scattered.

By default, the surface color is based on the z values. ChartDirector also supports using an optional w data series to determine the surface color. For example, the (x, y, z) may be the 3D coordinates of a geographic area, and w may be the temperature. In this case, the (x, y, z) determines the surface shape while w determines the surface color.

Arguments

ArgumentDefaultDescription
xData(Mandatory)An array of numbers representing the x data series.
yData(Mandatory)An array of numbers representing the y data series.
zData(Mandatory)An array of numbers representing the z data series.
wData[Empty_Array]An array of numbers containing an extra data series for determining the colors on the surface.

Return Value

None