How to plot inverted chart, and set default chart

Hi all

Is there any way to plot inverted chart. and also how to set my current chart as default chart ?

Inverted in the meaning of 1/price or "upside down" with negative values like -price ?

In short, you need to replace OHLC arrays with inverted values, for example

// invert values
C = 1 / C;
H = 1 / H;
L = 1 / L;
O = 1 / O;

and use PlotOHLC but you have to keep in mind that inversion changes H-L relationship (ie. high becomes lower than low), so you need to:

PlotOHLC( O, L, H, C, "Inverted chart", colorDefault, styleCandle );
4 Likes

This topic was automatically closed 100 days after the last reply. New replies are no longer allowed.