MTF Trailing SL Strategy [QuantNomad]

This is a Multi-Timeframe version of my Trailing SL Strategy.
Few weeks ago I published Trailing SL Strategy. There I used only basic Trailing SL to enter positions.
It worked pretty well so I tried to work on it a bit. I thought what if you can use the same ATR TSL on different timeframes and combine them into one signal.
In this strategy you can use only ATR stops and choose 3 other higher timeframes in addition to your current timeframe.
You'll see Trailing SL plotted on the chart form all these timeframes.

Entry Long position if all 4 time-frames agree on long signal.
Exit Long positions when at least 2 time-frames disagree on long signal.

Entry to Short position if all 4 time-frames agree on Short signal.
Exit from Short positions when at least 2 time-frames disagree on Short signal.

Here is the link to my basic Trailing SL Strategy:

הערות שחרור: Fixed backtesting range
הערות שחרור: Updated the way I get the data from Higher Timeframe
הסר מסקריפטים מועדפים הוסף לסקריפטים מועדפים
PineScript Programming: https://qntly.com/pinepro
TradingView Essential: https://qntly.com/tve

Access to Pro Indic.: https://qntly.com/proind

YouTube: https://qntly.com/youtube
Discord: https://qntly.com/discord
Telegram: https://qntly.com/tel


It did not use date range information for enter/exit
+1 השב
QuantNomad HighTopMoon
@HighTopMoon, Yep, updated the script, now it should work
+2 השב
I just realized that I misspelled "//@version=4 incorrectly which is why my Security Function didn't work.
Reeeeeeee hahah
Thank you. I have a question please:
in the security calls should we use barmerge.lookahead_off to get accurate backtesting? and will this affect the performance?
@HMS2MS, yep, never use lookeahead = on. It will screw your performance completely.
+1 השב
HMS2MS QuantNomad
@QuantNomad, yet you are using lookeahead = on in the script above. I am sure you have a good reason because you have very good experience. So may you please educate us about this.
@HMS2MS, I'm using it with historical operator to get the previous value on the close. It's a stable way to get this data without repainting.
HMS2MS QuantNomad
@QuantNomad, Now I understand. Thank you.
בית סורק מניות סורק מט"ח סורק מטבעות-קריפטו יומן כלכלי איך זה עובד‏ תכונות גרף מחירון הפנה חבר כללי הבית מרכז תמיכה כלים לאתרים וברוקרים יישומונים פתרונות גרפיים ספריית גרפים קלי משקל בלוג וחדשות טוויטר‏
פרופיל הגדרות פרופיל חשבון וחיוב חברים מופנים מטבעות לשוניות התמיכה שלי מרכז תמיכה רעיונות שפורסמו עוקבים עוקב הודעות פרטיות צ'אט התנתק