OPEN-SOURCE SCRIPT

Margin Debt YoY %

249
以下提供中英文版本,你可以依 TradingView 發布規範直接貼上使用:

中文說明
FINRA 保證金負債年增率 (FRED 替代數據)
本指標追蹤美國股市槓桿程度的年增率變化,作為觀察市場情緒與系統性風險的參考工具。
數據來源與計算方式
由於 TradingView 平台並未直接提供 FINRA 官方月度保證金負債數據,本指標改用 FRED(聖路易斯聯邦準備銀行)公布的季度數據 BOGZ1FL663067003Q(證券經紀商與交易商保證金貸款餘額)作為替代指標。此數據與 FINRA 每月公布的保證金負債高度相關,但統計口徑與頻率略有不同(季度 vs 月度),因此數值會與 FINRA 官方數據存在些微差異,僅供趨勢參考。
年增率計算方式為:當期數值與去年同期(4個季度前)相比的百分比變化。
視覺標示區間

🔴 過熱警戒帶(+20% ~ +45%):保證金負債年增率達此區間時,顯示市場槓桿擴張速度偏快,歷史上常出現在牛市末期或泡沫階段。
🟢 恐慌洗盤帶(-20% ~ -45%):年增率大幅萎縮時,顯示投資人正在去槓桿,常見於市場修正或恐慌性拋售期間。
⬜ 經濟衰退期(灰色背景):根據 NBER(美國國家經濟研究局)官方認定的衰退期間,資料取自 FRED 的 USREC 系列。

注意事項

保證金負債數據本身具有落後性,且季度/月度發布頻率遠低於股價數據,因此本指標不適合作為短線交易訊號,較適合用於中長期市場情緒與槓桿週期的觀察。
過熱與恐慌區間的數值門檻(±20%、±45%)是根據歷史經驗設定的參考範圍,並非精確的買賣訊號,使用者應搭配其他技術指標與基本面分析綜合判斷。
本指標僅供教育與研究用途,不構成任何投資建議。


English Description
FINRA Margin Debt YoY % (FRED Proxy)
This indicator tracks the year-over-year percentage change in U.S. stock market leverage, offered as a reference tool for gauging market sentiment and systemic risk.
Data Source and Methodology
Since TradingView does not provide a direct feed of FINRA's official monthly margin debt statistics, this indicator uses BOGZ1FL663067003Q from FRED (Federal Reserve Bank of St. Louis) — "Security Brokers and Dealers; Margin Accounts at Brokers and Dealers" — as a proxy. This FRED series is closely correlated with FINRA's monthly margin debt figures but differs in reporting frequency (quarterly vs. monthly) and methodology, so values will diverge slightly from official FINRA data. Use this indicator for trend observation rather than exact figures.
The year-over-year change is calculated by comparing the current value to the value four quarters (one year) prior.
Visual Zones

🔴 Overheat zone (+20% to +45%): Rapid expansion of margin debt, historically associated with late-cycle bull markets or bubble conditions.
🟢 Panic/washout zone (-20% to -45%): Sharp contraction in margin debt, typically seen during market corrections or forced deleveraging events.
⬜ Recession periods (gray background): Official U.S. recession dates as determined by the NBER (National Bureau of Economic Research), sourced from FRED's USREC series.

Notes

Margin debt data is inherently lagging, and its quarterly/monthly release frequency is much slower than price data. This indicator is better suited for observing medium- to long-term leverage cycles and sentiment shifts rather than short-term trading signals.
The overheat and panic thresholds (±20%, ±45%) are historically informed reference ranges, not precise buy/sell signals. Combine with other technical and fundamental analysis before making decisions.
This indicator is for educational and research purposes only and does not constitute financial advice.

Exención de responsabilidad

La información y las publicaciones no constituyen, ni deben considerarse como, asesoramiento o recomendaciones financieras, de inversión, de trading u otro tipo, proporcionadas o respaldadas por TradingView. Obtenga más información en Condiciones de uso.