Key Features:
Choosing between SMA or EMA for Moving Averages:
The user can select whether to use Simple Moving Averages (SMA) or Exponential Moving Averages (EMA) for the 20, 50, 100, and 200 periods.
Enable/Disable Buy/Sell signals based on different conditions:
The Candlestick Buy/Sell Signals can be enabled or disabled using enable_candlestick_signals.
The MACD-based Buy/Sell signals are controlled by enable_macd_signals.
The 50 MA-based Buy/Sell signals are controlled by enable_50ma_signals, and the logic for these signals is excluded when disabled.
Enable/Disable 100 MA Buy/Sell Signals:
The enable_100ma input allows the user to enable or disable the 100 MA Buy/Sell signals. This is disabled by default, but users can activate it.
ATR-Based Stop Loss and Take Profit:
The ATR (Average True Range) is used to calculate dynamic stop loss and take profit levels, with adjustable multipliers for both.
The option to plot stop loss and take profit levels using either "dots" or "lines" is also included.
Moving Average and Signal Plotting:
The 20 MA, 50 MA, 100 MA, and 200 MA are plotted with specific colors. The 100 MA is only plotted if enable_100ma is enabled.
Buy and Sell signals are plotted with labels above and below the bars.
Alerts:
Alerts are set for the Buy, Sell, and Any signal (for both Buy and Sell).
These alerts are based on the conditions for the candlestick patterns, MACD, and other signals.