OPEN-SOURCE SCRIPT
Telah dikemas kini

Mansfield RS+ - Relative Strength with Price Confirmation

393
Combines the Mansfield Relative Strength calculation (credit: stageanalysis) with a price action confirmation overlay (credit: bharatTrader) into a single indicator.

Calculation
The RS line measures daily stock price divided by weekly SPX close, normalized against a 52-week SMA of that ratio. Values above zero indicate outperformance vs. the S&P 500. Values below zero indicate underperformance.
Inputs

  • Symbol: benchmark index (default SP:SPX)
  • MA Length: lookback period for the zero line SMA (default 52)
  • Price Confirmation Period: SMA length for bubble logic (default 50)
  • RS Trend Range: lookback for zero line momentum color (default 5)
  • Show Bubbles: toggle price confirmation overlay
  • Show Background Colors: toggle Mansfield-style background


Reading the indicator
The zero line changes color based on RS momentum direction — green when RS is accelerating, red when decelerating.
Bubbles appear when price and its 50 SMA agree on direction. Green bubbles indicate price above a rising SMA. Red bubbles indicate price below a falling SMA.
RS above zero with green bubbles: RS and price both confirm, strongest long signal. RS above zero with red bubbles: RS positive but price weakening, use as a caution signal. RS below zero with green bubbles: price leading RS, early watch but not yet actionable. RS below zero with red bubbles: both confirm weakness, avoid.

Alerts included
  • RS crossed above/below zero
  • RS trend turned bullish/bearish


Credits:
Mansfield RS formula: [url=
Mansfield Relative Strength (Original Version) by stageanalysis

Price confirmation bubble logic: bharatTrader
Nota Keluaran
Added configurable value label size and color override option. Reduced bubble size. Removed unused background color inputs.
Nota Keluaran
Bug fix to make it work on smaller time frames.

Penafian

Maklumat dan penerbitan adalah tidak bertujuan, dan tidak membentuk, nasihat atau cadangan kewangan, pelaburan, dagangan atau jenis lain yang diberikan atau disahkan oleh TradingView. Baca lebih dalam Terma Penggunaan.