OPEN-SOURCE SCRIPT
宏观压力计 (Macro Stress Gauge)

call on green, sell on red
the Red Line represents US Treasury Yield momentum (the cost of capital), and the Green Line represents US Dollar momentum (the global liquidity valve).
When both lines spike and break above the 50 midline, it means money is both expensive and scarce. This is the dangerous "Double Kill" moment. At this time, you should hold cash and strictly avoid high-valuation tech stocks.
Conversely, if both the Red and Green lines fall below 50—and the background turns green—that is the macro "Goldilocks Zone." This implies a loose Fed and a weakening Dollar, representing peak risk appetite. You should boldly buy high-beta growth stocks or crypto without worrying about a broad market correction.
The most common scenario is divergence (one up, one down)—for example, if the Red Line rises while the Green Line falls. This usually signals Sector Rotation rather than a crash. In this environment, capital often flows from Tech into Industrials or Commodities; you just need to follow the "Sector Radar" mentioned earlier to allocate into the strong sectors.
To summarize simply, just stare at the middle line: when both lines are above it, it’s "Red Light: Stop"; when both are below, it’s "Green Light: Go." Now, take a look at your screen—if the background hasn't turned red, you can proceed to use the sector tools to hunt for opportunities.
the Red Line represents US Treasury Yield momentum (the cost of capital), and the Green Line represents US Dollar momentum (the global liquidity valve).
When both lines spike and break above the 50 midline, it means money is both expensive and scarce. This is the dangerous "Double Kill" moment. At this time, you should hold cash and strictly avoid high-valuation tech stocks.
Conversely, if both the Red and Green lines fall below 50—and the background turns green—that is the macro "Goldilocks Zone." This implies a loose Fed and a weakening Dollar, representing peak risk appetite. You should boldly buy high-beta growth stocks or crypto without worrying about a broad market correction.
The most common scenario is divergence (one up, one down)—for example, if the Red Line rises while the Green Line falls. This usually signals Sector Rotation rather than a crash. In this environment, capital often flows from Tech into Industrials or Commodities; you just need to follow the "Sector Radar" mentioned earlier to allocate into the strong sectors.
To summarize simply, just stare at the middle line: when both lines are above it, it’s "Red Light: Stop"; when both are below, it’s "Green Light: Go." Now, take a look at your screen—if the background hasn't turned red, you can proceed to use the sector tools to hunt for opportunities.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.