OPEN-SOURCE SCRIPT

SMA Indicator (20, 50, 100)

SMA Script for 20,50 and 100 days

Key Features:
SMA Source:
Users can select the source for SMA calculation (e.g., close, open, high, low, hl2, etc.) via the input.source() function.
Default: close.
Dynamic Customization:
Color: Choose a color for each SMA line.
Visibility: Toggle SMA visibility.
Source: Change the source data used for SMA calculation.
Simplicity: Everything is configurable directly through the script settings.
How to Use:
Paste this script into the Pine Editor on TradingView.
Click Add to Chart.
Open the script settings (gear icon):
Set the desired lengths, colors, and visibility for SMA 20, 50, and 100.
Choose the source (e.g., close, open, high, etc.) for SMA calculations.
This version provides complete flexibility for SMA visualization and customization.
Simple Moving Average (SMA)simplemovingaverage100simplemovingaverage200simplemovingaverages

開源腳本

在真正的TradingView精神中,這個腳本的作者以開源的方式發佈,這樣交易員可以理解和驗證它。請向作者致敬!您可以免費使用它,但在出版物中再次使用這段程式碼將受到網站規則的約束。 您可以收藏它以在圖表上使用。

想在圖表上使用此腳本?

免責聲明