Trades being missed.
Posted: Jun 10 2024
I am testing this simple code that compiles but sometimes does not take a trade even when conditions are met. Cannot see anything wrong in script.
Code: Select all
[IntrabarOrderGeneration = false]
variables: MyLo1(0), MyLo2(0);
condition1 = l < l[1] ;
if condition1 then
begin
MyLo2 = MyLo1;
MyLo1 = l;
end;
if MyLo1 < MyLo2 then
Buy ( "2LoLE" ) next bar at market ;