A bug in the OrderSend() function ? - page 3

 
tara:
Albanian is not forbidden:)


It's all in three lines.

if((Bid - iMA)< var*Point)  OrderSend();
if((iMA - Bid)< var*Point)  OrderSend();

something like

 
No, that won't do:)
 
pako:
I edited to post the code with fewer functions. The comments have shifted. And I didn't remove the sign where the ticket is... Of course it shouldn't be like that. But nevertheless, everything is fine there for bai.
 
hoz:
I edited to post the code with fewer functions. The comments have shifted. And I didn't remove the sign where the ticket is... Of course it shouldn't be like that. But nevertheless, everything is fine there for bai.
Do as I asked.
 
hoz:
I edited to post the code with fewer functions. The comments have shifted. And I didn't remove the sign where the ticket is... Of course it shouldn't be like that. But nonetheless, everything is fine there for the bay.

And you judge by the visualizer in the tester that it opens (draws) in a wrong place on the chart or in the demo - if in the tester, it's unclear what's drawing there, take time to debug the demo, display variables in the comment on the screen and observe whether the algorithm works or not. I asked because I saw a screenshot on previous pages with mid-January dates.

 
tara:
No, it doesn't work like that :)

As soon as the price comes within a certain distance of the wristbandif((Bid - iMA)< var*Point)
or if you want a lot of bubbles??????

also with a wrist cap

Ma1 = iMA(NULL,i_TF,i_fastMaPeriod,0,MODE_EMA,MODE_CLOSE,1);
Ma2 = iMA(NULL,i_TF,i_fastMaPeriod,0,MODE_EMA,MODE_CLOSE,2);

if(Ma1 > Ma2) вверх;
else          вниз;
 
tara:
Do as I asked.

Already done. I also increased the indent variable a little bit and there we go.... I guess it's not always possible to tell by eye.

I wonder, what else does lastBarTime variable globalization have effect on, besides performance? Its type is static, which means that the variable stores its value during the entire life of the program...

There is one more interesting thing. If I still use the wand in various functions, was it right that I declared it at once in the start? Or is it not very reasonable to get values on each tick in terms of resource consumption?

 
BeerGod:

Are you judging by the visualizer in the tester that it opens (draws) in the wrong place on the chart or on the demo? If in the tester, it is unclear what is drawing there, spend time on debugging the demo, display variables in the comment on the screen and observe the algorithm or not. I asked because I saw a screenshot on previous pages with mid-January dates.

Yeah, well, I'm running it in visual and watching... And what can it show wrong? After all, if you roll the TS on the clock or on H4 on demo, it can overwinter a few years :) ..... :) It's a real bummer, isn't it?
 
pako:

As soon as the price comes within a certain distance of the wristband if((Bid - iMA)< var*Point)
or if you want to have a lot of bacoffs ??????


Well it's the same and the bucaphs are the same (if we're talking about a signal):

if ( MathAbs(Ask - fastMa) <= i_thresholdFromMa * pt ) // ..зазор между ценой покупки и машки, <= i_thresholdFromMa..
        return(SIGNAL_BUY);                       // ..функция возвращает сигнал покупки
 
hoz:

Already done. I also increased the indent variable a little bit and there we go.... I guess it's not always possible to tell by eye.

I wonder, what else does lastBarTime variable globalization have effect on, besides performance? Its type is static, which means that the variable stores its value during the entire life of the program...

There is one more interesting thing. If I still use the wand in various functions, was it right that I declared it at once in the start? Or on every tick it doesn't make much sense in terms of resource consumption?

I'm a bit drunk and can't answer your question.