PROTECTED SOURCE SCRIPT
Telah dikemas kini Another EMA trend indicator

"Another EMA Trend Indicator" is a dynamic trend-following tool. Blending customizable Moving Averages (EMA or SMA) with an automated, visualized trade management system. It identifies bullish and bearish trend shifts based on short- and long-term MA crossovers, dynamically calculates optimal entry points, stop-losses, and take-profits, and visually manages trades on the chart with optional clouds, lines, and labels.
Main Features:
Moving Average Trend Detection:
Choice between EMA (Exponential Moving Average) or SMA (Simple Moving Average).
Two customizable lengths: a short MA and a long MA.
Detects bullish and bearish switches based on MA crossover events.
Entry, SL, and TP Calculation:
Entries are calculated dynamically after a signal using a combination of historical candle high/low analysis and a risk divider.
Stop-loss and take-profit levels are automatically set based on the trend's recent volatility and user-defined risk parameters.
Supports fixed or dynamic profit targets.
Risk Management Settings:
Define minimum and maximum acceptable profit percentages.
Set maximum stop-loss distance and apply a stop-loss multiplier for added flexibility.
Limit maximum trade duration to avoid endless open trades.
Trade Visualization:
Optional debug mode to display:
Entry, stop-loss, and take-profit lines.
Buy/sell signals via shapes on the chart.
Trend cloud between short and long MAs.
Historical trend levels for better visualization.
Dynamic Statistics Panel:
Real-time display of:
First trade date.
Total number of trades.
Number of profitable and losing trades.
Average and maximum trade duration.
Win rate and average profit/loss percentages.
Inputs:
MA Type: Choose between "EMA" or "SMA."
Short/Long MA Length: Customize lengths to control sensitivity.
Source: Apply to typical price values like hl2.
Risk Settings:
Minimum, maximum, and fixed profit percentages.
Stop-loss settings and risk dividers.
Trade Behavior Settings:
Max trade length.
Visualization Toggles:
Show/hide debug labels, lines, clouds.
Use Case:
This indicator is ideal for trend-following traders who prefer a semi-automated trading framework. It helps maintain consistency in entries and exits while visualizing important trend dynamics and trade health directly on the chart.
Best suited for swing trading crypto coins.
Main Features:
Moving Average Trend Detection:
Choice between EMA (Exponential Moving Average) or SMA (Simple Moving Average).
Two customizable lengths: a short MA and a long MA.
Detects bullish and bearish switches based on MA crossover events.
Entry, SL, and TP Calculation:
Entries are calculated dynamically after a signal using a combination of historical candle high/low analysis and a risk divider.
Stop-loss and take-profit levels are automatically set based on the trend's recent volatility and user-defined risk parameters.
Supports fixed or dynamic profit targets.
Risk Management Settings:
Define minimum and maximum acceptable profit percentages.
Set maximum stop-loss distance and apply a stop-loss multiplier for added flexibility.
Limit maximum trade duration to avoid endless open trades.
Trade Visualization:
Optional debug mode to display:
Entry, stop-loss, and take-profit lines.
Buy/sell signals via shapes on the chart.
Trend cloud between short and long MAs.
Historical trend levels for better visualization.
Dynamic Statistics Panel:
Real-time display of:
First trade date.
Total number of trades.
Number of profitable and losing trades.
Average and maximum trade duration.
Win rate and average profit/loss percentages.
Inputs:
MA Type: Choose between "EMA" or "SMA."
Short/Long MA Length: Customize lengths to control sensitivity.
Source: Apply to typical price values like hl2.
Risk Settings:
Minimum, maximum, and fixed profit percentages.
Stop-loss settings and risk dividers.
Trade Behavior Settings:
Max trade length.
Visualization Toggles:
Show/hide debug labels, lines, clouds.
Use Case:
This indicator is ideal for trend-following traders who prefer a semi-automated trading framework. It helps maintain consistency in entries and exits while visualizing important trend dynamics and trade health directly on the chart.
Best suited for swing trading crypto coins.
Nota Keluaran
"Error on bar {bar_index}: The requested historical offset ({num1}) is beyond the historical buffer's limit ({num2})." error fixNota Keluaran
Signals now seem to be more accurate but every crypto coin tends to have its sweet spot for minimum profit and trend offsetImprovements
- Trend detection
- Trade entry/profit/loss logic
- Trend lines (improved start of trend display)
New inputs
- Max entry length - candle amount to start entry or cancel signal
- Minimum trend offset - dynamic offset, changes a lot for signal accuracy
TODO:
- Option to automatically adjust inputs for best signal accuracy
- Performance improvements
Nota Keluaran
Improvements- Start time - input for more accurate trade statistics
- Added statistics for long and short trades
- Small change for signal entry accuracy
Nota Keluaran
Updated signal entry value logicNota Keluaran
- Minimum trend offset renamed to Default trend offset
- New option - Use automatic trend offset
- Small improvement on signal entry value
Nota Keluaran
- Renamed "Use automatic trend offset" to "Use automatic trend inputs"
- "Use automatic trend inputs" now checks offset and fixed profit inputs for optimal signals
Nota Keluaran
- Dropped automatic trend offset input/feature due to performance issues
- Rewrote indicator logic
Nota Keluaran
Option to debug eventsDefault is enabled. When enabled shows labels to catch up on events
- Entry(blue) - candle where entry was hit
- TP(green) - candle where take profit was hit
- SL(red) - candle where stop loss was hit
- Stopped(yellow) - entry was hit and TP or SL was not hit but algorithm decided to stop it gaining profit or taking a loss into statistics
- Cancelled(orange) - entry was not hit and signal disappeared
Nota Keluaran
Updated signal logicSkrip dilindungi
Skrip ini diterbitkan sebagai sumber tertutup. Akan tetapi, anda boleh menggunakannya dengan percuma dan tanpa had – ketahui lebih lanjut di sini.
Penafian
Maklumat dan penerbitan adalah tidak dimaksudkan untuk menjadi, dan tidak membentuk, nasihat untuk kewangan, pelaburan, perdagangan dan jenis-jenis lain atau cadangan yang dibekalkan atau disahkan oleh TradingView. Baca dengan lebih lanjut di Terma Penggunaan.
Skrip dilindungi
Skrip ini diterbitkan sebagai sumber tertutup. Akan tetapi, anda boleh menggunakannya dengan percuma dan tanpa had – ketahui lebih lanjut di sini.
Penafian
Maklumat dan penerbitan adalah tidak dimaksudkan untuk menjadi, dan tidak membentuk, nasihat untuk kewangan, pelaburan, perdagangan dan jenis-jenis lain atau cadangan yang dibekalkan atau disahkan oleh TradingView. Baca dengan lebih lanjut di Terma Penggunaan.