Due to Tradingview working restrictions, this indicator only works if is used in a timeframe lower (or equal) to one week, otherways shows an error red label showing this error.
All my scripts:
- Corrected the method to detect > weekly timeframe
- Deactivate the SMA if current timeframe is > Week
- Show errors or not definable with switch