PROTECTED SOURCE SCRIPT
Fear–Greed Index

What it does
This indicator compresses multiple behavioral signals into a single Fear–Greed Index (FGI) that ranges from –100 (extreme fear) to +100 (extreme greed). It blends three psychology-based components—Prospect Theory, Herding, and Social Impact Theory (SIT)
How it thinks
Prospect Theory (CPT)
Looks at the balance of gains vs. losses in recent returns.
Herding (Brock–Durlauf / Ising-style)
Counts the signs of recent returns (up vs. down) to measure “magnetization” (are most bars up or down.
Social Impact Theory (SIT)
Measures today’s return strength relative to recent volatility (strength), how concentrated recent moves were in the most recent quarter of the window (immediacy), and participation via volume relative to its recent average (number).
How to use it
Rising toward +100 → crowd risk-on/greed; falling toward –100 → risk-off/fear.
Treat extreme zones as context, not standalone trade signals—combine with price structure, volume, and risk management.
Script protegido
Esse script é publicada como código fechado. No entanto, você pode usar ele livremente e sem nenhuma limitação – saiba mais aqui.
Aviso legal
As informações e publicações não devem ser e não constituem conselhos ou recomendações financeiras, de investimento, de negociação ou de qualquer outro tipo, fornecidas ou endossadas pela TradingView. Leia mais em Termos de uso.
Script protegido
Esse script é publicada como código fechado. No entanto, você pode usar ele livremente e sem nenhuma limitação – saiba mais aqui.
Aviso legal
As informações e publicações não devem ser e não constituem conselhos ou recomendações financeiras, de investimento, de negociação ou de qualquer outro tipo, fornecidas ou endossadas pela TradingView. Leia mais em Termos de uso.