US/SPY- Financial Regime Index Swing Strategy Credits: concept inspired by EdgeTools Bloomberg Financial Conditions Index (Proxy)
Improvements: eight component basket, inverse volatility weights, winsorization option( statistical technique used to limit the influence of outliers in a dataset by replacing extreme values with less extreme ones, rather than removing them entirely), slope and price gates, exit guards, table and gradients.
Summary in one paragraph
A macro regime swing strategy for index ETFs, futures, FX majors, and large cap equities on daily calculation with optional lower time execution. It acts only when a composite Financial Conditions proxy plus slope and an optional price filter align. Originality comes from an eight component macro basket with inverse volatility weights and winsorized return z scores that produce a portable yardstick.
Scope and intent
Markets: SPY and peers, ES futures, ACWI, liquid FX majors, BTC, large cap equities.
Timeframes: calculation daily by default, trade on any chart.
Default demo: SPY on Daily.
Purpose: convert broad financial conditions into clear swing bias and exits.
Originality and usefulness
Unique fusion: return z scores for eight liquid proxies with inverse volatility weighting and optional winsorization, then slope and price gates.
Failure mode addressed: false starts in chop and early shorts during easy liquidity.
Testability: all knobs are inputs and the table shows components and weights.
Portable yardstick: z scores center at zero so thresholds transfer across symbols.
Method overview in plain language
Base measures
Return basis: natural log return over a configurable window, standardized to a z score. Winsorization optional to cap extremes.
Components
EQ US and EQ GLB measure equity tone.
CREDIT uses LQD over HYG. Higher credit quality outperformance is risk off so sign is flipped after z score.
RATES2Y uses two year yield, sign flipped.
SLOPE uses ten minus two year yield spread.
USD uses DXY, sign flipped.
VOL uses VIX, sign flipped.
LIQ uses BIL over SPY, sign flipped.
Each component is smoothed by the composite EMA.
Fusion rule
Weighted sum where weights are equal or inverse volatility with exponent gamma, normalized to percent so they sum to one.
Signal rule
Long when composite crosses up the long threshold and its slope is positive and price is above the SMA filter, or when composite is above the configured always long floor.
Short when composite crosses down the short threshold and its slope is negative and price is below the SMA filter.
Long exit on cross down of the long exit line or on a fresh short signal.
Short exit on cross up of the short exit line or on a fresh long signal, or when composite falls below the force short exit guard.
What you will see on the chart
Markers on suggestion bars: L for long, S for short, LX and SX for exits.
Reference lines at zero and soft regime bands at plus one and minus one.
Optional background gradient by regime intensity.
Compact table with component z, weight percent, and composite readout.
Table fields and quick reading guide
Component: EQ US, EQ GLB, CREDIT, RATES2Y, SLOPE, USD, VOL, LIQ.
Z: current standardized value, green for positive risk tone where applicable.
Weight: contribution percent after normalization.
Composite: current index value.
Reading tip: a broadly green Z column with slope positive often precedes better long context.
Inputs with guidance
Setup
Calc timeframe: default Daily. Leave blank to inherit chart.
Lookback: 50 to 1500. Larger length stabilizes regimes and delays turns.
EMA smoothing: 1 to 200. Higher smooths noise and delays signals.
Normalization
Winsorize z at ±3: caps extremes to reduce one off shocks.
Return window for equities: 5 to 260. Shorter reacts faster.
Weighting
Weight lookback: 20 to 520.
Weight mode: Equal or InvVol.
InvVol exponent gamma: 0.1 to 3. Higher compresses noisy components more.
Signals
Trade side: Long Short or Both.
Entry threshold long and short: portable z thresholds.
Exit line long and short: soft exits that give back less.
Slope lookback bars: 1 to 20.
Always long floor bfci ≥ X: macro easy mode keep long.
Force short exit when bfci < Y: macro stress guard.
Confirm
Use price trend filter and Price SMA length.
View
Glow line and Show component table.
Symbols
SPY ACWI HYG LQD VIX DXY US02Y US10Y BIL are defaults and can be changed.
Realism and responsible publication
No performance claims. Past is not future.
Shapes can move intrabar and settle on close.
Execution is on standard candles only.
Honest limitations and failure modes
Major economic releases and illiquid sessions can break assumptions.
Very quiet regimes reduce contrast. Use longer windows or higher thresholds.
Component proxies are ETFs and indexes and cannot match a proprietary FCI exactly.
Strategy notice
Orders are simulated on standard candles. All security calls use lookahead off. Nonstandard chart types are not supported for strategies.
Entries and exits
Long rule: bfci cross above long threshold with positive slope and optional price filter OR bfci above the always long floor.
Short rule: bfci cross below short threshold with negative slope and optional price filter.
Exit rules: long exit on bfci cross below long exit or on a short signal. Short exit on bfci cross above short exit or on a long signal or on force close guard.
Position sizing
Percent of equity by default. Keep target risk per trade low. One percent is a sensible starting point. For this example we used 3% of the total capital
Commisions
We used a 0.05% comission and 5 tick slippage
Legal
Education and research only. Not investment advice. Test in simulation first. Use realistic costs.
Credit
Equity Risk PremiumInspired by the article "2020's Best Performing Hedge Fund Warns Of 'Incredible Move' Around The Election" from ZeroHedge:
This script explores the relationship and attempts to find dislocation between equity risk (VIX) and high-yield corporate debt risk (VXHYG, The Cboe VXHYG Index is an estimate of the expected 30-day volatility of the return on iShares' High Yield Grade ETF (HYG). VXHYG is derived by applying the VIX algorithm to options on HYG).
The basic logic is (closing price of VIX / closing price of VXHYG) - 1. When equity risk is high and credit risk is low, the value of premium will be high, and vice-versa.
“'Equity volatility is almost inescapably high. Is that a good form of insurance? The payoff profiles are nothing like they were back in January. Whereas in credit, we’re almost back to where we were in January.
I find today the risk-reward profile of credit to be basically among the worst, relative to other things, I’ve seen in my career,' Weinstein said. 'A VIX at 20 used to be quite a feat. Here we are at 30, and the credit market hasn’t blinked.'
As a result of the gaping divergence between the VIX and credit spreads - the two had moved in tandem for years, but in August the two series blew out as the VIX started rising as spreads kept falling - Weinstein has pounced on the trade, betting on vol compression."
When equity risk premium is high, the market may be forming a local top.
When equity risk premium is low, the market may be forming a local bottom.
Make sure to select your current timeframe on the dropdown menu.
Credit Creation Degree_Debt/M1 [Xiaolai(Sean) Chen] TathaGadaReflect on my previous script "Credit Creation Degree" which is M2/M1 money stock value is the reflection of the degree of credit created which was mentioned by Ray Dalio in his 30 min video "How the Market and Economic Machines Work"
This is another option which compares the Federal Government Debt: Total domestic debt with M1 Money stock
Credit degree will finally decrease in the Long-Term Debt circle.
Credit Creation Degree_Debt/M1 [Xiaolai(Sean) Chen]Reflect on my previous script "Credit Creation Degree" which is M2/M1 money stock value is the reflection of the degree of credit created which was mentioned by Ray Dalio in his 30 min video "How the Market and Economic Machines Work"
This is another option which compares the Federal Government Debt: Total domestic debt with M1 Money stock
Credit degree will finally decrease in the Long-Term Debt circle.
Xiaolai(Sean)Chen_Credit Creation DegreeM2/M1 money stock value is the reflection of the degree of credit created which was mentioned by Ray Dalio in his 30 min video "How the Market and Economic Machines Work"
Credit degree will finally decrease in the Long-Term Debt circle.





