Features:
ATR (Average True Range) Settings:

Allows the user to adjust the ATR period and multiplier for the Supertrend calculation.
Offers an option to choose between the standard ATR or a simple moving average (SMA) for ATR calculation.
Source Price:

Users can select from four different EMAs (EMA1, EMA2, EMA3, EMA4) or use the default HL2 (average of high and low) as the source price for calculating the Supertrend.
The EMAs are calculated with adjustable periods.
Supertrend Calculation:

The Supertrend is calculated using the selected source price and ATR values. The trend direction is determined based on whether the closing price is above or below the Supertrend lines.
Trend Plotting:

The script plots the Supertrend lines: green for an uptrend and red for a downtrend. These lines are updated based on trend reversals.
Buy/Sell Signals:

The script generates buy and sell signals based on trend reversals (when the trend changes from up to down or vice versa).
Buy and sell signals are marked on the chart using shapes and labels.
Background Highlighting:

The background is highlighted in green for an uptrend and red for a downtrend. This can be turned on or off using the highlighting option.
EMA Lines:

The selected EMAs (EMA1, EMA2, EMA3, EMA4) are plotted on the chart for reference.
Alerts:

Alerts are triggered when a buy or sell signal occurs or when the trend direction changes.
Customization:
You can adjust the ATR period, multiplier, and EMA periods.
You can enable or disable the display of buy/sell signals and background highlighting.
The script allows for flexibility in choosing which EMA to use for the source price.
This script provides a versatile Supertrend indicator with multiple EMA options and various customization choices for traders who want more control over their strategy.
buysellsignalemacrossovermoving_averageMoving AveragesPrice Volume Trend (PVT)supertrendTrend Analysis

نص برمجي مفتوح المصدر

قام مؤلف هذا النص البرمجي بنشره وجعله مفتوح المصدر، بحيث يمكن للمتداولين فهمه والتحقق منه، وهو الأمر الذي يدخل ضمن قيم TradingView. تحياتنا للمؤلف! يمكنك استخدامه مجانًا، ولكن إعادة استخدام هذا الرمز في المنشور يخضع لقواعد‎‎قوانين الموقع. يمكنك جعله مفضلاً لاستخدامه على الرسم البياني.

هل تريد استخدام هذا النص البرمجي على الرسم البياني؟

إخلاء المسؤولية