Search Locate Previous Next Contents

ch.Scatter – x/y scatter plot

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

ch.Scatter data

Example

ch.Set 'Head' 'XY Scatter Plot'
ch.Set('Ycap' 'Age')('XCAP' 'Weight')
ch.Scatter MAT
ch.Scatter (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 ...
ch.Plot – line graphs
CategoriseBy – category variable
Scatterplot Style
Versus – scatter versus this


Continue to: ch.Step – step charts
© Copyright Causeway Graphical Systems Ltd 2003