Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes - page 261

 
Alexey Viktorov:

How do you determine what doesn't work? The price of the object is not at the bottom. That's why you can't see that one point. Make five or seven points and you'll see.


I know it's not at the bottom, there's a point at the object, like the beginning of the object.

 
mt1002:

A hint I'm drawing an object:

ObjectCreate(0, "good_"+(string)s,OBJ_ARROW,0,0,0,0); // create an arrow

ObjectSetInteger(0, "good_"+(string)s,OBJPROP_ARROWCODE,252); // set arrow code

ObjectSetInteger(0, "good_"+(string)s,OBJPROP_TIME,Time[1]); // set time

ObjectSetDouble(0, "good_"+(string)s,OBJPROP_PRICE,High[1]+GetArrowInterval(2));

ObjectSet("good_"+(string)s,OBJPROP_COLOR,Lime);

ObjectSet("good_"+(string)s,OBJPROP_WIDTH,2);

s++;

How to make the arrow go 10 pips higher than the bar's high. High[1]+0.0001 doesn't do it(((

pr - percentage
double GetArrowInterval(double pr=4) {
  if(pr<=0) pr=1;
 return((ChartGetDouble(0,CHART_PRICE_MAX)-ChartGetDouble(0,CHART_PRICE_MIN))/100*pr);
}
//-----------------------------------------------------------------------------------------------
 
Vitaly Muzichenko:
pr is a percentage

No, that's bullshit.

 
mt1002:

No, that's just bullshit.

this is the best solution, always the arrow at the same distance on different timeframes, but adding some points is really bullshit

 

Hi all.

I would like to see an indicator that builds high and low levels by bodies (you can use shadows) for a certain period of time.

In other words it would be possible to set the period from which to draw. Is there such a thing?

 
aksiman:

Hi all.

I would like to see an indicator that builds high and low levels by bodies (you can use shadows) for a certain period of time.

In other words it would be possible to set the period from which to draw. Do you have such an indicator?

Look for it.

 
Vitaly Muzichenko:

This is the best solution, the arrow is always at the same distance on different timeframes, but adding some points is really bullshit.


I don't get it, pr=4 or pr=80 is drawing almost the same and almost on the candlestick's haha.

 
mt1002:

I don't get it, the pr=4 or pr=80 is drawing almost the same and almost on the candlestick's jai.

Print it, and look at the price of the function

Print( GetArrowInterval(5) );
 
Artyom Trishkin:

Search.


You're just going to say something, aren't you?
Always pissed off people like that. If you don't want to help, don't write anything.
There are 4200 indicators. I wrote it here on purpose. Maybe someone has used one recently and remembers the names.

 
aksiman:

You're just going to say something, aren't you?
Always pissed people off. If you don't want to help, don't write anything.
There's 4200 indicators. I wrote it here on purpose. Maybe someone has used one recently and remembers the names.

Two iMa (.......) at HIGH and LOU prices with an average of 1.
Reason: