- ago
When having WL set a trailing stop price via an ATR multiple (see code below), is WL sampling the ATR at the "current" bar [idx] or the "entry" bar [LastPosition.EntryBar]?

CODE:
CloseAtTrailingStop(p, TrailingStopType.ATR, 2.5, "T-Stop");
This question is a major issue because the value of ATR[idx] is constantly changing and it typically peaks in the middle of a position. But at what value is ATR[idx] most reliable for assigning a trailing stop?

The most reproducible volatility value is Median(TrueRange) in the time-middle of the position, but one can't determine that until the position closes. I have thought about waiting until the Median(TrueRange) stabilizes while owning the position, then assigning a trailing stop at that point. But that means not having a trailing stop exit available at the start of the position; not ideal. Your thoughts?

For those wondering, I'm doing a statistical analysis on how to best assign a trailing stop. But the problem is really a catch 22 if you're trying to do this in real time while the position is open. Of course, one can always do an after-the-fact (backtest) statistical analysis.
0
220
0 Replies

Reply

Bookmark

Sort
Currently there are no replies yet. Please check back later.