OPEN-SOURCE SCRIPT

ATR Based TMA Bands [NeuraAlgo]

108
ATR-Based TMA Bands [NeuraAlgo]

ATR-Based TMA Bands is a volatility-adaptive channel system built around a smoothed Triangular Moving Average (TMA).
It identifies trend direction, momentum shifts, and reversal opportunities using a combination of TMA structure and ATR-driven channel expansion.

Perfect for traders who want a clean, intelligent, and adaptive market framework.
Made by NeuraAlgo.
snapshot
🔷 How It Works
1. 🔹 TMA Midline (Core Trend)

The indicator builds a smooth and stable midline using:
  1. 📐 Triangular Moving Average
  2. 🔄 Additional EMA smoothing


This creates a low-noise trend curve that reacts cleanly to real momentum changes.

2. 📈 Volatility-Adjusted Bands
The channels are built from:
  • 📊 Standard Deviation × Expansion Multiplier
  • 📏 Three ATR-based outer layers


These bands:
  • Expand in high volatility
  • Contract in stable markets
  • Reveal pullbacks, breakout zones, and exhaustion points


3. 🔁 Trend Tilt Algorithm
Slope is measured using an ATR-normalized tilt formula:
Pine Script®
atrBase = ta.atr(smoothLen) tilt = (midline - midline[1]) / (0.1 * atrBase)


This classifies the trend into:
  • Bullish
  • Bearish
  • Neutral


The bar colors and midline adjust automatically to match market direction.

4. 🔄 Reversal Detection (Turn Signals)
The indicator flags directional flips:
  1. Turn Up → bearish → bullish shift
  2. Turn Down → bullish → bearish shift

snapshot
These are early reversal alerts ideal for swing traders.

5. 🎯 Flip Buy / Flip Sell Signals
Deep volatility extensions create high-probability re-entry zones:
  1. Flip Buy → price rebounds from oversold ATR zone
  2. Flip Sell → price rejects from overbought ATR zone


Great for:
  • Mean-reversion entries
  • Trend re-tests
  • Pullback trades
  • Exhaustion signals

snapshot
📌 How to Use This Indicator
✔ Trend Trading
  1. Follow trend using tilt-colored candles
  2. Use midline as dynamic trend filter
  3. Use channels for breakout/pullback entries

✔ Reversal Trading
  1. Watch for Turn Up / Turn Down labels
  2. Flip signals show where the market is over-stretched

✔ Risk Management
  1. ATR channels automatically adjust to volatility
  2. Helps with smarter SL/TP placement


⭐ Best For
  1. Trend traders
  2. Swing traders
  3. Reversal hunters
  4. Volatility lovers


Anyone wanting a smart, clean technical framework

💡 Core Features
  1. TMA-smoothed trend detection
  2. Multi-layer ATR expansion channels
  3. Intelligent trend tilt algorithm
  4. Turn Up / Turn Down reversal markers
  5. Flip Buy / Flip Sell exhaustion signals
  6. Adaptive bar coloring
  7. Clean and professional visual design

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.