SharpPlot Reference > SharpPlot Methods > NewYAxis Method

SharpPlot.NewYAxis Method

Partial reset to allow independent secondary Y-axis.

public void NewYAxis();

This call resets all the properties associated with the Y-axis, allowing any number of independently ranged vertical axes. The default alignment is ‘right’ but you may change the axis style, or use the XIntercept property, to place the new axis anywhere you like. This allows you to have as many Y-axes as you like, but more than 2 is unlikely to work well in practice.

Example

sp.NewYAxis();

This method is typically used for charts which compare two series with very different ranges, for example currencies such as the Dollar and the Yen.

See also ...

SharpPlot Members | SharpPlot.XIntercept Property


Send comments on this topic
© Dyalog Ltd 2021