OPEN-SOURCE SCRIPT
Range Oscillator Strategy + Stoch Confirm / Long Only by (Mara)

Strategy Overview
This script is a long-only trend-following strategy that combines:
– Range-based trend filter (inspired by "Range Oscillator" by Zeiierman)
– Stochastic (7 / 3 / 3) for pullback & entry timing
– EMA Exit Filter for adaptive exits as default 70
Use it to backtest, tweak, and study how this combination behaves on different markets.
1. Trend Filter
Trade longs only when the trend filter value is above the user-defined Threshold.
If the filter ≤ Threshold → no new long entries.
Threshold is adjustable in the settings.
2. Pullback Logic – Stochastic (7 / 3 / 3)
While trend is bullish:
Wait for %K to pull back below a chosen level (e.g. 50 or 20),
then look for a bullish %K over %D crossover.
All parameters are configurable.
3. Entry Conditions (Long Only)
– Trend filter > Threshold
– Stoch pullback condition met
– Bullish %K > %D at bar close
No short entries.
4. Stop Loss & Take Profit
Configurable Stop Loss and optional Take Profit.
Use Inputs to compare fixed RR vs. indicator/exit-based management.
5. EMA Exit Filter (Optional)
Additional custom exit logic to react faster to weakening conditions.
Toggleable in Inputs.
6. How to Test
Try on BTC and major markets (1D / 4D / 1H) and review:
net profit, drawdown, win rate, and robustness over multiple years.
7. Disclaimer
This script is for testing, education, and strategy development only.
It is not financial advice and not a guarantee of profits.
Always manage your own risk.
This script is a long-only trend-following strategy that combines:
– Range-based trend filter (inspired by "Range Oscillator" by Zeiierman)
– Stochastic (7 / 3 / 3) for pullback & entry timing
– EMA Exit Filter for adaptive exits as default 70
Use it to backtest, tweak, and study how this combination behaves on different markets.
1. Trend Filter
Trade longs only when the trend filter value is above the user-defined Threshold.
If the filter ≤ Threshold → no new long entries.
Threshold is adjustable in the settings.
2. Pullback Logic – Stochastic (7 / 3 / 3)
While trend is bullish:
Wait for %K to pull back below a chosen level (e.g. 50 or 20),
then look for a bullish %K over %D crossover.
All parameters are configurable.
3. Entry Conditions (Long Only)
– Trend filter > Threshold
– Stoch pullback condition met
– Bullish %K > %D at bar close
No short entries.
4. Stop Loss & Take Profit
Configurable Stop Loss and optional Take Profit.
Use Inputs to compare fixed RR vs. indicator/exit-based management.
5. EMA Exit Filter (Optional)
Additional custom exit logic to react faster to weakening conditions.
Toggleable in Inputs.
6. How to Test
Try on BTC and major markets (1D / 4D / 1H) and review:
net profit, drawdown, win rate, and robustness over multiple years.
7. Disclaimer
This script is for testing, education, and strategy development only.
It is not financial advice and not a guarantee of profits.
Always manage your own risk.
Open-source Skript
Ganz im Sinne von TradingView hat dieser Autor sein/ihr Script als Open-Source veröffentlicht. Auf diese Weise können nun auch andere Trader das Script rezensieren und die Funktionalität überprüfen. Vielen Dank an den Autor! Sie können das Script kostenlos verwenden, aber eine Wiederveröffentlichung des Codes unterliegt unseren Hausregeln.
Haftungsausschluss
Die Informationen und Veröffentlichungen sind nicht als Finanz-, Anlage-, Handels- oder andere Arten von Ratschlägen oder Empfehlungen gedacht, die von TradingView bereitgestellt oder gebilligt werden, und stellen diese nicht dar. Lesen Sie mehr in den Nutzungsbedingungen.
Open-source Skript
Ganz im Sinne von TradingView hat dieser Autor sein/ihr Script als Open-Source veröffentlicht. Auf diese Weise können nun auch andere Trader das Script rezensieren und die Funktionalität überprüfen. Vielen Dank an den Autor! Sie können das Script kostenlos verwenden, aber eine Wiederveröffentlichung des Codes unterliegt unseren Hausregeln.
Haftungsausschluss
Die Informationen und Veröffentlichungen sind nicht als Finanz-, Anlage-, Handels- oder andere Arten von Ratschlägen oder Empfehlungen gedacht, die von TradingView bereitgestellt oder gebilligt werden, und stellen diese nicht dar. Lesen Sie mehr in den Nutzungsbedingungen.