OPEN-SOURCE SCRIPT
MACD/PPO ALMA Edition

MACD – a trend-following indicator that "always too late" indicates what's happening on the chart.
To make this indicator traditionally considered "good but too late" based on the ALMA moving average:
The Arnaud Legoux Moving Average (ALMA) is a technical indicator designed to reduce lag and noise in price data by applying a Gaussian filter, offering a smoother and more responsive alternative to traditional SMAs and EMAs.
Key Aspects of ALMA:
Key Parameters: ALMA uses three main settings: Window Size (length), Offset (offsets focus on recent prices, typically 0.85), and Sigma (controls the smoothness of the curve, typically 6).
Reduced Latency: By shifting the Gaussian distribution toward the most recent data (offset to 1), ALMA responds faster to price changes, helping to avoid false signals in uncertain, low-volatility conditions.
Using ALMA instead of EMA/SMA in the code significantly improves the smoothness and speed of signal appearance, which facilitates decision-making.
The code features three significant changes compared to traditional methods:
1. The price is determined based on (open+close)/2 - why is this? - theoretically, the volume-weighted asset value is always between the opening and closing prices, so I considered averaging it to be a good value.
2. Additional coloring of the trend change after the curves intersect to indicate an increase or decrease in trend strength.
3. Using PPO normalization allows for comparison of the dynamics of different stocks, as its values are normalized percentages and not absolute MACD values.
I most often use Heikin Ashi – the chart is very smooth and does not significantly affect the quick identification of trend changes.
To make this indicator traditionally considered "good but too late" based on the ALMA moving average:
The Arnaud Legoux Moving Average (ALMA) is a technical indicator designed to reduce lag and noise in price data by applying a Gaussian filter, offering a smoother and more responsive alternative to traditional SMAs and EMAs.
Key Aspects of ALMA:
Key Parameters: ALMA uses three main settings: Window Size (length), Offset (offsets focus on recent prices, typically 0.85), and Sigma (controls the smoothness of the curve, typically 6).
Reduced Latency: By shifting the Gaussian distribution toward the most recent data (offset to 1), ALMA responds faster to price changes, helping to avoid false signals in uncertain, low-volatility conditions.
Using ALMA instead of EMA/SMA in the code significantly improves the smoothness and speed of signal appearance, which facilitates decision-making.
The code features three significant changes compared to traditional methods:
1. The price is determined based on (open+close)/2 - why is this? - theoretically, the volume-weighted asset value is always between the opening and closing prices, so I considered averaging it to be a good value.
2. Additional coloring of the trend change after the curves intersect to indicate an increase or decrease in trend strength.
3. Using PPO normalization allows for comparison of the dynamics of different stocks, as its values are normalized percentages and not absolute MACD values.
I most often use Heikin Ashi – the chart is very smooth and does not significantly affect the quick identification of trend changes.
نص برمجي مفتوح المصدر
بروح TradingView الحقيقية، قام مبتكر هذا النص البرمجي بجعله مفتوح المصدر، بحيث يمكن للمتداولين مراجعة وظائفه والتحقق منها. شكرا للمؤلف! بينما يمكنك استخدامه مجانًا، تذكر أن إعادة نشر الكود يخضع لقواعد الموقع الخاصة بنا.
إخلاء المسؤولية
لا يُقصد بالمعلومات والمنشورات أن تكون، أو تشكل، أي نصيحة مالية أو استثمارية أو تجارية أو أنواع أخرى من النصائح أو التوصيات المقدمة أو المعتمدة من TradingView. اقرأ المزيد في شروط الاستخدام.
نص برمجي مفتوح المصدر
بروح TradingView الحقيقية، قام مبتكر هذا النص البرمجي بجعله مفتوح المصدر، بحيث يمكن للمتداولين مراجعة وظائفه والتحقق منها. شكرا للمؤلف! بينما يمكنك استخدامه مجانًا، تذكر أن إعادة نشر الكود يخضع لقواعد الموقع الخاصة بنا.
إخلاء المسؤولية
لا يُقصد بالمعلومات والمنشورات أن تكون، أو تشكل، أي نصيحة مالية أو استثمارية أو تجارية أو أنواع أخرى من النصائح أو التوصيات المقدمة أو المعتمدة من TradingView. اقرأ المزيد في شروط الاستخدام.