Writing

Momentum52: Reconstructing Medium-Horizon Momentum and 52-Week-High Signals in Python

Frozen-historical-universe replication of a long-only momentum policy with executable Python, formal definitions, a chronological holdout and reproducibility audits.

Computational Finance · Cenk Ufuk Yildiran · 26 October 2026

Abstract

This study prepares an independent, transparent replication of Momentum52, the second strategy generation in From Breakouts and Momentum to Short-Term Reversal. The model combines intermediate-horizon returns that skip the most recent trading month with 52-week-high proximity, a 55-session breakout filter, benchmark-relative momentum, volume confirmation, and a benchmark trend gate. An independently programmed Jupyter notebook reconstructs the originally governed long-only trading policy and records its own data, signals and portfolio outcomes. It retains the original study dates and the historically failed development/validation rule rather than retrospectively tuning its parameters. In contrast with Post 1, it does not re-download constituent membership from Wikipedia: it uses a frozen reconstruction of the original paper’s 399-member historical universe, while re-downloading stock and MDY price histories through Yahoo Finance.

Executed reconstruction: Using the frozen 399-stock list and independently retrieved Yahoo Finance daily price histories, the full historical run produced 113 trades and −34.2906% portfolio return. The independently funded development and original-validation windows produced 59 trades (+1.4010%) and 54 trades (−34.1037%), respectively; the common comparison window produced 53 trades (−9.7493%). All four summary results match the earlier paper to the displayed precision. These are retrospective reproductions of known historical dates, not a new untouched holdout.

1. Research motivation and evidence

Jegadeesh and Titman (1993) establish medium-term return continuation in diversified winner–loser equity portfolios. Carhart (1997) highlights momentum exposure and trading costs in performance measurement, while Novy-Marx (2012) emphasizes the timing of the intermediate formation window. Momentum52 therefore uses both twelve-minus-one-month and six-minus-one-month return measures, approximated by 252, 126 and 21 trading-session lookbacks. The strategy is not a conventional diversified long–short momentum factor: at most two stocks are held, on the long side, in a $5,000 account.

George and Hwang (2004) provide a research motivation for conditioning on the 52-week high; Lee and Swaminathan (2000) study the relation between trading volume and momentum. Neither literature source establishes the precise 95% high-proximity cutoff, 55-session breakout window, 1.2 volume-ratio filter or weighted percentile score used here. These thresholds are historical project choices, documented and left unchanged.

Finally, Daniel and Moskowitz (2016) identify momentum crash risks, and Sullivan, Timmermann and White (1999) document pitfalls from selecting technical rules after observing historical outcomes. The original Momentum52 research failed its holdout gate; the present reconstruction is not a pretext for revising the strategy after that result.

2. Frozen research universe and independently downloaded prices

Exact research stock list: Download all 399 frozen stock tickers (CSV) · View the membership reconstruction and SHA-256 checksum (JSON). These are the fixed tickers used by the Post 3 notebook, not a live index-membership list. The list was reconstructed from the original-paper reconciliation documented in Post 1; it is not presented as a byte-for-byte copy of the original trading repository’s universe file.

The research population is a frozen 399-stock list inferred from the historical paper’s constituent reconciliation in Post 1, Section 6. That audit identified 393 common constituents, six original-only tickers (CPRI, ILMN, OLN, P, SAM, TWLO) and seven Post-1-only securities (AGNC, CORT, CTVA, EAT, FORM, HUBS, MOG-A). We reconstruct the original membership as the 400 Post-1 manifest tickers minus those seven and plus those six. This is an evidence-based reconstructed membership, not a byte-for-byte copy of the original trading-system universe file. Its CSV file and provenance JSON are SHA-256 checked before signal generation. Future index additions do not change the frozen list.

The notebook downloads historical daily OHLCV from Yahoo Finance via yfinance: 13 September 2021 to 10 September 2026 inclusive, with auto_adjust=False, repair=False, and actions=False. The benchmark is MDY, the S&P MidCap 400 ETF. Its fixed historical reference calendar has 1,254 trading sessions. The notebook records downloaded data fingerprints and fails if a frozen original member has no available Yahoo price history. No replacement ticker is silently introduced.

Historical membership is contemporaneous and projected backwards, not point-in-time membership. This exposes the study to survivorship and delisting bias, and price histories may have been revised since the original paper. Yahoo’s Close is generally split-adjusted even when auto_adjust=False, and should not be confused with a dividend-adjusted total-return series.

3. Mathematical signal specification

Let Ci,tC_{i,t}, Hi,tH_{i,t}, Li,tL_{i,t}, Oi,tO_{i,t} and Vi,tV_{i,t} be a security’s daily close, high, low, open and volume. The indicator families use only data available at or before the signal-session close.

3.1 Momentum formation windows

MOMi,t12−1=Ci,t−21Ci,t−252−1,MOMi,t6−1=Ci,t−21Ci,t−126−1. MOM^{12-1}_{i,t}=\frac{C_{i,t-21}}{C_{i,t-252}}-1, \qquad MOM^{6-1}_{i,t}=\frac{C_{i,t-21}}{C_{i,t-126}}-1.

The 21-session skip is a deliberate implementation of intermediate-horizon momentum rather than immediate prior-month return continuation.

3.2 Breakout, high proximity and volume

Bi,t55=max⁡1≤j≤55Hi,t−j,H52i,t=Ci,tmax⁡1≤j≤252Hi,t−j. B^{55}_{i,t}=\max_{1\le j\le55}H_{i,t-j}, \qquad H52_{i,t}=\frac{C_{i,t}}{\max_{1\le j\le252}H_{i,t-j}}.
VRi,t=Vi,t120∑j=019Vi,t−j,ADVi,t20=120∑j=019Ci,t−jVi,t−j. VR_{i,t}=\frac{V_{i,t}}{\frac1{20}\sum_{j=0}^{19}V_{i,t-j}}, \qquad ADV^{20}_{i,t}=\frac1{20}\sum_{j=0}^{19}C_{i,t-j}V_{i,t-j}.

The present high does not enter either trailing high reference; this prevents a current-bar look-ahead in the breakout decision.

3.3 Relative strength and benchmark gate

For observations aligned on common security–MDY dates,

RSi,t126=(Ci,tCi,t−126−1)−(CMDY,tCMDY,t−126−1). RS^{126}_{i,t}=\left(\frac{C_{i,t}}{C_{i,t-126}}-1\right)-\left(\frac{C_{MDY,t}}{C_{MDY,t-126}}-1\right).

The benchmark regime passes when CMDY,t>SMAMDY,t50>SMAMDY,t200C_{MDY,t}>SMA^{50}_{MDY,t}>SMA^{200}_{MDY,t}. A candidate also requires C≥10C\ge10, ADV20≥$5mADV^{20}\ge\$5m, C>SMA50>SMA200C>SMA^{50}>SMA^{200}, a rising SMA50 over 20 sessions, C≥B55C\ge B^{55}, VR≥1.2VR\ge1.2, MOM12−1≥0.10MOM^{12-1}\ge0.10, MOM6−1≥0.05MOM^{6-1}\ge0.05, H52≥0.95H52\ge0.95, RS126≥0RS^{126}\ge0, and ATR14/C≤0.08ATR^{14}/C\le0.08. ATR is the arithmetic 14-bar mean of true range.

3.4 Cross-sectional ranking

For the eligible candidates on each signal date, let Qt(xi)Q_t(x_i) be the average-tie percentile rank of variable xix_i. The governed score is

Si,t=100[0.30Qt(MOM12−1)+0.20Qt(MOM6−1)+0.25Qt(RS126)+0.15Qt(H52)+0.10Qt(VR)]. S_{i,t}=100[0.30Q_t(MOM^{12-1})+0.20Q_t(MOM^{6-1})+0.25Q_t(RS^{126})+0.15Q_t(H52)+0.10Q_t(VR)].

Scores are rounded to two decimals. Candidates are ordered by score, then raw 126-session relative strength, then raw 12–1 momentum, descending. Ranking is only across eligible names that same day, not the full set of index members.

4. Portfolio implementation

Signals are formed at the session close, with simulated buys on the next trading-session open after five basis points adverse slippage. Starting capital is $5,000, with at most two concurrent positions, two new orders per day, $2,500 per position and $125 planned initial risk per position. A one-dollar commission applies to each buy and sell order. ATR-based initial stops use the signal-date fraction clip⁡(1.5ATR14/C,0.04,0.08)\operatorname{clip}(1.5ATR^{14}/C,0.04,0.08), applied to the executed entry price. After a 10% favorable price move, a 5% trailing stop activates. The maximum holding window is 30 sessions, including the entry session.

The daily-bar engine processes an overnight gap through an active stop before opening new positions, then intraday stop lows before favourable high-based trailing changes. Actual losses may exceed the planned $125 due to overnight gaps and fees. These conventions duplicate the historical project design but do not establish realistic execution in all market states.

5. Historical research chronology and the validation gate

The following archived paper figures were independently reproduced by the executed Post 3 notebook using the same governed membership and a newly downloaded historical Yahoo Finance price dataset. The matching portfolio summary does not, by itself, establish that every transaction and raw OHLCV observation is byte-identical to the archived originals:

Original segmentDatesTradesHistorical portfolio returnProfit factor
Full historical runFixed calendar through 10 Sep 2026113−34.2906%0.7974
Development21 Oct 2022 – 20 Feb 202559+1.4010%1.0169
Original holdout21 Feb 2025 – 10 Sep 202654−34.1037%0.5985
Retrospective common-period comparison30 Jul 2025 – 10 Sep 202653−9.7493%0.8844

The original three-part acceptance rule demanded a development profit factor at least 1.20, a validation profit factor at least 1.20, and positive validation return. It failed. All four archived total-return, trade-count and profit-factor figures were reproduced to the displayed precision. The historical three-part gate still fails; re-evaluating the already-known validation dates is not an independent new holdout.

6. Replication deliverables and limitations

The executed notebook saved the ranked signal calendar, separate trade ledgers and equity curves, download audits, OHLCV fingerprints, portfolio-performance summary, MDY comparison figures and a reproducibility manifest. The download audit reports 399/399 successful stock-price downloads (398 with at least 280 observations and therefore signal-eligible). The signal calendar contains 1,977 ranked signals on 459 dates. The simulator remains offline for trading and creates no broker orders.

Momentum52 portfolio wealth versus MDY over the common period

Momentum52 and MDY common-period drawdowns

The notebook was executed and its outputs audited; full reproducibility still depends on availability of the historical vendor data, corporate-action conventions and the frozen constituent list.

The most important limitations are (i) reconstructed present-day rather than point-in-time membership, (ii) Yahoo Finance data revisions and possibly unavailable historical symbols, (iii) uncertainty of intraday high–low ordering, (iv) stylized transaction costs, (v) the unusually concentrated two-stock portfolio, and (vi) selection and holdout contamination inherited from earlier strategy development.

Research downloads: Jupyter notebook · Python requirements · Frozen 399-ticker universe · Universe provenance and hash.

References

Back to Writing