Search Locate Previous Next Contents

chScatter – x/y scatter plot

This function is almost equivalent to calling chPlot having set a ‘versus’ property. However it makes for more readable code, and can additionally handle category data on the Y-axis.

chScatter data

Example

chSet 'Head' 'XY Scatter Plot'
chSet('Ycap' 'Age')('XCAP' 'Weight')
chScatter MAT
chScatter (6 5 4 2)(9 6 7 8)

It automatically turns on markers and turns off lines. If you call it with a text variable, the (sorted) unique values will be used to label the Y-axis and the current value of the ‘versus’ property will be used to generate the X-axis.

See also ...
chPlot – line graphs
CategoriseBy – category variable
Scatterplot Style
Versus – scatter versus this


Continue to: chStep – step charts
© Copyright Causeway Graphical Systems Ltd 2003