Hi everyone, new to AB and figuring out some basics and stuck on something which I'm sure is simple.
I wanted to set a sell stop at the low of the bar on which the long signal was generated. I used portions of the code found here:
It works! However, I do not understand why. Specifically the line:
stopLevelLong = Ref( L, -1 ); // use previous bar low
Is that not creating an array? How is the value of "stopLevelLong" only being set on the bar of the buy signal?
On a related note, if I could visualize the arrays, it might be helpful. Is there a way to view the arrays in a data window?
Yes it creates array, but...
ApplyStop() samples the value of the array passed as 'amount' at entry and holds it for how long trade takes, unless you use volatile flag.
Visualising arrays and other techiques:
You can use the explore function. Think that is what you are looking for....
This topic was automatically closed 100 days after the last reply. New replies are no longer allowed.