Download MetaTrader 5

Does PLOT_ARROW_SHIFT-like property exist in MQL4?

To add comments, please log in or register
kypa
88
kypa  

Hello!

I want to achieve the effect of built-in Fractal indicator - shifting arrow plots above an below price action by a certain number of pixels.

In MQL5 PLOT_ARROW_SHIFT does the job perfectly, but I couldn't find anything like that in MQL4.

I'm aware a similar effect can be done with another array summing up original array and a certain price margin, but I don't want to do that.

kypa
88
kypa  

Maybe at least changing anchor point of the arrows plotted?

The built in Fractal indicator arrows seem like having top anchor points for the down Fractals and bottom anchor points for the up ones.

Custom indicator arrow plot appears with something like center anchor point.

Is there a way to change these anchor points?

Taras Slobodyanik
20229
Taras Slobodyanik  
   chart_heigth_pix=(int)ChartGetInteger(0,CHART_HEIGHT_IN_PIXELS,0);
   chart_price_min=ChartGetDouble(0,CHART_PRICE_MIN,0);
   chart_price_max=ChartGetDouble(0,CHART_PRICE_MAX,0);

   //pips in one pixel
   pips_in_pix=((chart_price_max-chart_price_min)) / chart_heigth_pix;
kypa
88
kypa  
Taras Slobodyanik:

I know that is one way to do it, but it will need additional arrays and it will need recalculation on every chart rescaling.

I'm more willing to plot the arrows with a loop function as objects than this.

Thanks for reply anyway

To add comments, please log in or register