OPEN-SOURCE SCRIPT
EMA Trend Pullback with Risk Reward Signals

EMA Trend Pullback with Risk Reward Signals is a trend-following indicator that detects pullback opportunities within established EMA trends and automatically calculates projected entry, stop-loss, and take-profit levels using a configurable risk-reward ratio.
The script uses EMA 25, EMA 50, and EMA 100 alignment to define trend direction and waits for pullbacks into the moving averages before generating confirmation signals.
Features
EMA 25, EMA 50, and EMA 100 trend structure
Bullish trend detection
Bearish trend detection
Pullback recognition to EMA 25 or EMA 50
Candle confirmation filters
Automatic entry level calculation
Automatic stop-loss calculation
Automatic take-profit calculation
Configurable risk-reward ratio
Alert conditions for bullish and bearish signals
Visual signal labels on chart
Inputs
Risk Reward Ratio
Controls the distance of the projected take-profit level relative to risk.
SL Buffer (%)
Adds a percentage buffer around the EMA50-based stop-loss level.
How It Works
Bullish Setup
EMA25 is above EMA50.
EMA50 is above EMA100.
Price pulls back to EMA25 or EMA50.
A bullish confirmation candle closes above EMA25.
A bullish signal is generated.
Bearish Setup
EMA25 is below EMA50.
EMA50 is below EMA100.
Price pulls back to EMA25 or EMA50.
A bearish confirmation candle closes below EMA25.
A bearish signal is generated.
Risk Management
For each signal:
Entry = Signal candle close
Stop Loss = EMA50 plus buffer
Take Profit = Risk × User RR Ratio
Alerts
Available alerts:
Bullish Signal
Bearish Signal
Users can create TradingView alerts directly from these conditions.
Limitations
Signals depend on EMA-based trend definitions.
Performance may vary across instruments and timeframes.
The indicator does not guarantee future price movement.
High-volatility markets may produce additional noise.
Notes
Signals are confirmed only after bar close.
Designed primarily for trend continuation analysis.
Risk management settings should be adjusted according to market conditions.
The script uses EMA 25, EMA 50, and EMA 100 alignment to define trend direction and waits for pullbacks into the moving averages before generating confirmation signals.
Features
EMA 25, EMA 50, and EMA 100 trend structure
Bullish trend detection
Bearish trend detection
Pullback recognition to EMA 25 or EMA 50
Candle confirmation filters
Automatic entry level calculation
Automatic stop-loss calculation
Automatic take-profit calculation
Configurable risk-reward ratio
Alert conditions for bullish and bearish signals
Visual signal labels on chart
Inputs
Risk Reward Ratio
Controls the distance of the projected take-profit level relative to risk.
SL Buffer (%)
Adds a percentage buffer around the EMA50-based stop-loss level.
How It Works
Bullish Setup
EMA25 is above EMA50.
EMA50 is above EMA100.
Price pulls back to EMA25 or EMA50.
A bullish confirmation candle closes above EMA25.
A bullish signal is generated.
Bearish Setup
EMA25 is below EMA50.
EMA50 is below EMA100.
Price pulls back to EMA25 or EMA50.
A bearish confirmation candle closes below EMA25.
A bearish signal is generated.
Risk Management
For each signal:
Entry = Signal candle close
Stop Loss = EMA50 plus buffer
Take Profit = Risk × User RR Ratio
Alerts
Available alerts:
Bullish Signal
Bearish Signal
Users can create TradingView alerts directly from these conditions.
Limitations
Signals depend on EMA-based trend definitions.
Performance may vary across instruments and timeframes.
The indicator does not guarantee future price movement.
High-volatility markets may produce additional noise.
Notes
Signals are confirmed only after bar close.
Designed primarily for trend continuation analysis.
Risk management settings should be adjusted according to market conditions.
Skrip open-source
Dengan semangat TradingView yang sesungguhnya, pembuat skrip ini telah menjadikannya sebagai sumber terbuka, sehingga para trader dapat meninjau dan memverifikasi fungsinya. Salut untuk penulisnya! Meskipun Anda dapat menggunakannya secara gratis, perlu diingat bahwa penerbitan ulang kode ini tunduk pada Tata Tertib kami.
Build your trading tools with AI : algotim.com
All content provided by AlgoTim (algo_aakash) is for informational and educational purposes only. Trading involves risk, and past performance does not guarantee future results.
All content provided by AlgoTim (algo_aakash) is for informational and educational purposes only. Trading involves risk, and past performance does not guarantee future results.
Pernyataan Penyangkalan
Informasi dan publikasi ini tidak dimaksudkan, dan bukan merupakan, saran atau rekomendasi keuangan, investasi, trading, atau jenis lainnya yang diberikan atau didukung oleh TradingView. Baca selengkapnya di Ketentuan Penggunaan.
Skrip open-source
Dengan semangat TradingView yang sesungguhnya, pembuat skrip ini telah menjadikannya sebagai sumber terbuka, sehingga para trader dapat meninjau dan memverifikasi fungsinya. Salut untuk penulisnya! Meskipun Anda dapat menggunakannya secara gratis, perlu diingat bahwa penerbitan ulang kode ini tunduk pada Tata Tertib kami.
Build your trading tools with AI : algotim.com
All content provided by AlgoTim (algo_aakash) is for informational and educational purposes only. Trading involves risk, and past performance does not guarantee future results.
All content provided by AlgoTim (algo_aakash) is for informational and educational purposes only. Trading involves risk, and past performance does not guarantee future results.
Pernyataan Penyangkalan
Informasi dan publikasi ini tidak dimaksudkan, dan bukan merupakan, saran atau rekomendasi keuangan, investasi, trading, atau jenis lainnya yang diberikan atau didukung oleh TradingView. Baca selengkapnya di Ketentuan Penggunaan.