Strategies
Gold Safe-Haven Window After US Equity Shock Days: Long XAUUSD.SPOTMETAL for N Sessions After a >=k-Sigma SPY Down Session, Optional Haven-Unwind Short Leg (Cross-Venue Signal SPY.USEQ -> Spot Gold, 1-DAY, Long-Short)
Outcome: Verifying
GoldHavenAfterSpyShock
Gold Safe-Haven Window After US Equity Shock Days: Long XAUUSD.SPOTMETAL for N Sessions After a >=k-Sigma SPY Down Session, Optional Haven-Unwind Short Leg (Cross-Venue Signal SPY.USEQ -> Spot Gold, 1-DAY, Long-Short)
Hypothesis
Implementation
Cross-venue event strategy. Signal: the SPY.USEQ daily close-to-close return divided by its trailing 60-session return std, where the std uses only the sessions BEFORE the current one (shock score = -ret/std). Trade: XAUUSD.SPOTMETAL on 1-DAY bars. When a SPY session's score is >= shock_z, the strategy buys spot gold at the next gold session open (platform next_open_fill) with 50% of equity notional, unlevered, and holds for long_hold_sessions gold sessions. A new shock during the long restarts the clock and adds no size. With reversal_leg='on', the long is flipped into a short with ONE market order at the end of the hold, and the short is held for reversal_hold_sessions. A new shock during the short flips back to long. Each position carries a reduce-only intrabar STOP_MARKET 4% from its average entry price, which is 2% of equity at the stop. It is re-armed on every opening or reversing fill. calculate_signal returns the latest SPY shock score as a continuous value.
Backtest and paper results are hypothetical. Trading involves risk of loss.