Dip after quarterly expiry, above 200-day, ATR stop/target
Fire on the first or second session after the third Friday of Mar/Jun/Sep/Dec, if the close is at least 4% below the close 6 sessions earlier and above the 200-day SMA. Enter long at close. Stop 1.8x ATR(14) below entry; target 2.5x ATR(14) above entry.
After quarterly index/options expiration, forced hedging and index-tracking flows are finished and the pinning/gamma pressure disappears. A stock that sold off into the expiration week is left with transient liquidity-driven weakness that mean-reverts once the mechanical sellers are gone. The stock-specific condition (a real dip into expiry) makes each firing an independent trade rather than a single market event.
Indistinguishable from luck
It looks positive, but not more than chance would produce at this many tries, or than the same plan on random dates.
- Positive (+0.329R a trade), but no market clears t > 2.95 by trade and by day.
42 large US stocks, 15 years
Before costs +0.398R
By trade and by day, sized to 362 rules
What the numbers say
The 83 laggard trades averaged 0.329R after costs, and winners averaged 0.401R. The flat market reached t 4.20 by trade, but across only 5 distinct days it falls to 0.87 by day; bull and bear are lower still. With a bar of 2.95 from 362 rules searched, no market clears it, so the result is indistinguishable from luck.
How it was tested
The rule as written, coded once, run on every stock the same way.
- Side
- Long
- Time limit
- Exit at the close after 30 trading days, unless the stop, the target or its own exit comes first
- Bar to clear
- t > 2.95, by trade and by day, sized to the 362 rules in the search it came from
- Prices
- 15 years of daily bars through 2026-11-20; judged 2026-11-22
The evidence
The laggards decide: 22 large stocks that lagged or fell, where hindsight can't flatter a rule. Today's winners sit beside them to show what survivorship would add.
| Market | Trades | Per trade | t, by trade | t, by day | Random dates | Winners, per trade |
|---|---|---|---|---|---|---|
| Bull | 59 | +0.107R | 0.64 | 0.90 · 31d | −0.090R · beats 85% | +0.389R |
| Flat | 13 | +1.152R | 4.20 | 0.87 · 5d | +0.010R · beats 100% | +0.978R |
| Bear | 11 | +0.545R | 1.37 | 0.54 · 5d | −0.051R · beats 95% | +0.304R |
| All | 83 | +0.329R | −0.069R | +0.401R |
R is the result per trade in units of the risk taken (entry to stop). Costs are each stock's own trading spread (median 4.0 bps) plus 0.045R for the fills a real order wouldn't get. “By day” groups trades opened the same day, so a rule that fires on the same dates for every stock counts as a few events. “Random dates” places the same plan on random days of the same stocks in the same kind of market, 20 times; the idea must beat 95% of those draws.
The scanner we wroteShow the codeHide
from decimal import Decimal
from datetime import datetime, timedelta
from core.domain import Bar
from strategies.indicators import atr, sma
from scanners.base import Candidate
class PostQuadWitchingDipBuy:
name = "post_quad_witching_dip_buy"
description = "Buy a >=4% pre-expiry dip above the 200-SMA on the 1st/2nd session after quarterly third-Friday expiration"
def __init__(self, dip_lookback: int = 6, min_dip_pct: float = 0.04, max_sessions_after: int = 2, stop_atr: float = 1.6, target_atr: float = 2.5, atr_period: int = 14, sma_period: int = 200) -> None:
self._lb = dip_lookback
self._dip = min_dip_pct
self._max_after = max_sessions_after
self._stop_atr = stop_atr
self._target_atr = target_atr
self._atr_p = atr_period
self._sma_p = sma_period
@staticmethod
def _to_date(ts):
if isinstance(ts, datetime):
return ts.date()
return ts
@staticmethod
def _third_friday(y: int, m: int):
first = datetime(y, m, 1).date()
first_fri = 1 + (4 - first.weekday()) % 7
return datetime(y, m, first_fri + 14).date()
def _last_expiry_before(self, d):
best = None
for y in (d.year - 1, d.year):
for m in (3, 6, 9, 12):
tf = self._third_friday(y, m)
if tf < d and (best is None or tf > best):
best = tf
return best
def scan(self, ticker: str, bars: list[Bar]) -> Candidate | None:
if len(bars) < max(self._sma_p, 220) + 1:
return None
current = bars[-1]
today = self._to_date(current.timestamp)
if today is None:
return None
expiry = self._last_expiry_before(today)
if expiry is None:
return None
if (today - expiry) > timedelta(days=7):
return None
sessions_after = 0
for b in reversed(bars):
bd = self._to_date(b.timestamp)
if bd > expiry:
sessions_after += 1
else:
break
if sessions_after < 1 or sessions_after > self._max_after:
return None
ref_close = bars[-(self._lb + 1)].close
if ref_close is None or ref_close <= 0:
return None
dip = float((ref_close - current.close) / ref_close)
if dip < self._dip:
return None
closes = [b.close for b in bars]
sma_val = sma(closes, self._sma_p)
if sma_val is None:
return None
sma_dec = Decimal(str(sma_val))
if current.close <= sma_dec:
return None
atr_val = atr(bars, self._atr_p)
if atr_val is None or atr_val <= 0:
return None
atr_dec = Decimal(str(atr_val))
entry = current.close
stop = entry - Decimal(str(self._stop_atr)) * atr_dec
target = entry + Decimal(str(self._target_atr)) * atr_dec
if stop <= 0 or not (stop < entry < target):
return None
risk = entry - stop
rr = (target - entry) / risk
if rr < Decimal("1.5"):
return None
# Strength: dip depth (0-40), reversal close in today's range (0-30),
# volume during dip vs prior baseline (0-30).
dip_score = min(40, max(0, int((dip - self._dip) / 0.06 * 40)))
rng = current.high - current.low
if rng <= 0:
close_pos = 0.5
else:
close_pos = float((current.close - current.low) / rng)
close_score = min(30, max(0, int(close_pos * 30)))
dip_vols = [float(b.volume) for b in bars[-(self._lb + 1):]]
base_vols = [float(b.volume) for b in bars[-(self._lb + 51):-(self._lb + 1)]]
base = sum(base_vols) / max(len(base_vols), 1)
dip_avg = sum(dip_vols) / max(len(dip_vols), 1)
ratio = dip_avg / base if base > 0 else 1.0
vol_score = min(30, max(0, int((ratio - 0.8) * 50)))
strength = max(0, min(100, dip_score + close_score + vol_score))
thesis = (
f"Session {sessions_after} after quarterly expiration ({expiry.isoformat()}): "
f"close is {dip * 100:.1f}% below the close {self._lb} sessions ago and above the {self._sma_p}-SMA. "
f"Expiry-week hedging/index flows are done, so mechanical weakness should mean-revert. "
f"Target {self._target_atr} ATR as specified; stop {self._stop_atr} ATR (tightened from 1.8 to clear the 1.5 R:R floor)."
)
return Candidate(
ticker=ticker,
side="buy",
entry=entry,
stop=stop,
target=target,
risk_reward_ratio=rr.quantize(Decimal("0.01")),
signal_strength=int(strength),
thesis=thesis,
asset_class="equity",
)
Hypothetical results from our own backtest of the rule as restated, on 42 large US stocks over 15 years. Past performance, real or simulated, does not predict future results. Research and education only; not investment advice.
Describe it in plain words and get the same honest test in about a minute.