Jess Tran
AboutJourneySkillsContactBlog

Jess Tran

© 2026 Finance & Commodities

GitHubPhone: +1 (832) 853-2336Resume
Journey

Project, Fall 2026

Commodity Multi-Basket TSMOM Strategy & Portfolio Risk Threshold Model

Does a plain twelve-month trend signal make money on commodity futures after costs, and how sure can we be that it isn't luck?

A rules-based long/short trend-following strategy on a basket of liquid commodity futures, backtested the way a systematic desk would review it: lookahead-free, gross and net of costs, volatility-targeted, benchmarked, with parameter sensitivity and an explicit overfitting discussion.

Code and data on GitHub

Method.

In short: each month, go long the commodities that rose over the past year and short the ones that fell, with each position sized to carry the same risk.

The signal

For each of 13 commodity futures, compare today's price with its price 12 months (252 trading days) ago: higher means long, lower means short. Positions are reset on the last trading day of each month. This is plain time-series momentum as documented by Moskowitz, Ooi and Pedersen (2012), and no parameter was chosen by looking at this data.

Why it might work

Three textbook mechanisms make trend more than a coin flip:

  • Slow information diffusion. News is absorbed gradually, so prices drift rather than jump.
  • Under- and over-reaction. Investors anchor early in a trend and herd late in it.
  • Hedging pressure. Producers and consumers pay speculators a premium to take the other side of their hedges, and that premium tends to sit with the trend.

None of these is a guarantee. The aim is to test an off-the-shelf version honestly, not to find the best-performing variant.

How it's built

  • Signal. The sign of the 252-day trailing return: +1, −1, or 0 on a tie, with no skip month. Shorter lookbacks (63, 126 and 189 days) and a 21-day skip are tested only as robustness variants.
  • Sizing. Two stages. Each instrument is scaled to 10% annualised volatility (60-day rolling) and split evenly across the live instruments; then the whole book is scaled to 10% portfolio volatility, with gross leverage capped at 3×. The cap never binds: gross leverage averages 1.10× and peaks at 2.23×.
  • Trading and costs. 321 monthly rebalances, each traded one day after the signal, at 5 basis points one way. Turnover of 5.59× a year cost 0.29% a year, or 7.1 percentage points over 25 years. Roll costs are not modelled, because roll dates are not visible in the data.
  • Benchmarks. Three, on the same calendar: an equal-weight long-only basket of the same 13 futures; the same basket scaled to the same 10% volatility, so the comparison is not about leverage; and the Bloomberg Commodity Index (^BCOM), which rolls its contracts.
  • Statistics. All on daily returns with a zero risk-free rate: the Sharpe t-statistic, a 95% block-bootstrap interval, the Probabilistic Sharpe Ratio, and the Deflated Sharpe Ratio of Bailey and López de Prado, which corrects for the 192 configurations tried.

Every parameter was fixed in a configuration file before the first backtest ran.

The data.

In short: 25 years of free daily futures prices, cleaned by fixed rules and frozen in a snapshot, so every number on this page can be reproduced.

  • Source. Daily front-month settlement prices from Yahoo Finance for 14 futures across energy, metals, grains, softs and livestock, pulled once on 8 September 2026 and committed to the repository with checksums.
  • Calendar and gaps. 7,268 trading days from October 1997 to September 2026. Gaps of up to 5 days are filled with a zero return; longer gaps stay missing.
  • Negative oil prices. Returns are divided by the absolute previous price, so WTI's −$37.63 settlement on 20 April 2020 still gives a finite number, and daily returns are clipped to ±50%. Exactly two days were clipped, both WTI: 20 April 2020 (−306%) and 21 April 2020 (+127%).
  • Quality gate. At least 10 years of history, at most 5% of days filled, and no gap longer than 20 days. Platinum fails on a 53-day gap, leaving 13 instruments. Each joins on its own first valid signal, so the early years run with fewer names (12.8 live on average).

Results.

In short: a small positive return after costs, but too weak to rule out luck.

From April 2001 to September 2026 the strategy made 3.14% a year net of costs at 10.82% volatility: a net Sharpe ratio of 0.34 (0.37 before costs), with a worst drawdown of −40.42%. It survived its own costs and held up out of sample.

It is not a strong result. The Sharpe's 95% bootstrap interval runs from −0.04 to 0.72, and once the 192 configurations tested are accounted for, the Deflated Sharpe Ratio is 0.324: the result cannot be told apart from the best of 192 lucky draws.

The equal-weight long-only basket of the same futures did better (Sharpe 0.71), largely because the free price series never pay the cost of rolling contracts, which flatters any long position. The Bloomberg Commodity Index, which does roll, made 0.88% a year (Sharpe 0.14) over the same window.

Show the numbers
MetricStrategy (gross)Strategy (net)EW long-only (net)EW vol-targeted (net)^BCOM
Annualised return3.43%3.14%10.48%6.85%0.88%
Annualised volatility10.82%10.82%15.70%10.66%16.21%
Sharpe ratio0.370.340.710.670.14
Sortino ratio0.520.481.020.960.19
Max drawdown-39.46%-40.42%-48.19%-41.32%-75.00%
Max drawdown duration (days)15622442244527004534
Calmar ratio0.090.080.220.170.01
Hit rate (daily)51.58%51.51%53.01%53.01%51.54%
Hit rate (monthly)53.27%52.29%59.48%59.80%52.63%
Skew-0.11-0.11-0.15-0.22-0.27
Excess kurtosis2.252.252.882.122.68
Best month11.42%11.39%14.16%9.16%12.99%
Worst month-11.76%-11.77%-18.24%-11.54%-21.34%
Turnover (x per year)5.595.590.020.91n/a
Average gross leverage1.101.101.000.74n/a
Leverage cap binds (share of days)0.00%0.00%n/a0.00%n/a
Average instruments live12.8012.8013.0013.00n/a
Sharpe t-statistic1.851.713.603.400.68
Sharpe CI low (bootstrap)-0.01-0.040.310.25-0.27
Sharpe CI high (bootstrap)0.740.721.131.110.55
Probabilistic Sharpe (vs 0)0.9670.9571.0001.0000.751
Trials counted192192111
Sharpe hurdle (DSR)0.430.430.000.000.00
Deflated Sharpe0.3720.3241.0001.0000.751
Days64106410641064106356
First day2001-04-022001-04-022001-04-022001-04-022001-04-02
Last day2026-09-072026-09-072026-09-072026-09-072026-07-17

Three things to read off the figures:

Growth of $1, gross and net, against three benchmarks

  • Strategy (gross)
  • Strategy (net)
  • EW long-only (net)
  • EW vol-targeted (net)
  • Bloomberg Commodity Index
1.02.04.08.0200420082012201620202024

Log scale. Weekly closes, April 2001 to September 2026; the index ends in July 2026.

Show the numbers
Year endStrategy (gross)Strategy (net)EW long-only (net)EW vol-targeted (net)Bloomberg Commodity Index
20011.021.020.910.910.85
20021.071.071.221.181.07
20031.081.071.461.391.28
20041.141.131.651.521.38
20051.231.212.161.851.62
20061.381.362.492.011.58
20071.401.373.262.431.75
20081.421.392.452.281.07
20091.371.353.672.711.32
20101.581.545.173.441.54
20111.501.464.813.271.34
20121.391.354.933.241.32
20131.571.524.533.001.21
20141.831.774.002.681.01
20151.971.903.362.350.75
20161.551.494.062.700.83
20171.481.414.272.820.84
20181.451.394.052.690.74
20191.341.274.482.920.77
20201.491.415.582.880.74
20211.781.687.363.540.94
20221.881.778.193.891.07
20231.821.717.733.730.94
20241.821.718.514.080.93
20252.302.1410.164.741.07
20262.362.2012.615.39n/a
  • The long-only basket beat it, partly by artifact. Its 10.48% a year comes from front-month prices that track the spot price and never pay the roll; the index that does roll made 0.88% a year with a −75.00% drawdown. The strategy is short about half the time, so it is flattered less. A fair comparison needs back-adjusted data, which the free source does not provide.
  • The vol-targeted basket is the tougher benchmark. At the same 10% risk it made 6.85% a year (Sharpe 0.67) with a −41.32% drawdown. On this data, the trend signal did not beat simply owning the basket at the same risk; any edge would have to show in crises (see By year).
  • It did what it was built to do. Realised volatility was 10.82% against a 10% target, the leverage cap never bound, and costs took only 0.03 off the Sharpe. Drawdowns were long and shallow rather than sharp: the worst, −40.42%, took 2,442 trading days (about ten years) to recover, and the worst single month was −11.77%.

Drawdowns: long and shallow rather than sharp

  • Strategy (net)
  • EW long-only (net)
-50%-40%-30%-20%-10%0%200420082012201620202024
Show the numbers
SeriesWorst weekly-close drawdown
Strategy (net)-40.42%
EW long-only (net)-48.19%

Robustness.

In short: across 192 variations of the rules, the pre-set default ranks near the top, twelve-month trend is the strongest setting, and most variants earn little after costs.

192 configurations. Lookback (63, 126, 189 or 252 days) × volatility window (20, 60 or 120 days) × estimator (rolling or EWMA) × rebalancing (monthly or daily) × skip (0 or 21 days) × lag (1 or 2 days), each at costs of 0, 5, 10 and 20 bps. Every configuration counts as a trial for the Deflated Sharpe Ratio, whether or not it was ever looked at.

At 5 bps the net Sharpe ratios range from −0.29 to 0.47, with a median of 0.12, and 74.5% are positive. The pre-set default, 0.34, ranks 12th of 192. The best (0.47) is the default with a 120-day volatility window and daily rebalancing; the worst (−0.29) is a 63-day lookback with a 20-day window and a two-day lag.

Net Sharpe at 5 bps, by lookback and volatility window

Other parameters at their a-priori defaults; the default cell is outlined.

Lookback ↓ / vol →
20d
60d
120d
63d
-0.18
-0.03
0.08
126d
0.07
0.16
0.29
189d
0.13
0.09
0.20
252d
0.27
0.34
0.41

Lookback and volatility window. With the other settings at their defaults, the 252-day row reads 0.27, 0.34 and 0.41 across windows of 20, 60 and 120 days: the longest lookback is the best row, and a longer window helps. The 63-day row is negative everywhere. The result belongs to twelve-month trend, not to one tuned cell.

Costs. The default's Sharpe falls from 0.37 with no costs to 0.34 at 5 bps, 0.31 at 10 bps and 0.26 at 20 bps. The grid median crosses zero between 10 and 20 bps, and the share of positive trials falls from 96% to 36%. A monthly twelve-month signal is cheap to trade; most of the grid is not.

Net Sharpe against the cost assumption

  • Default trial
  • Grid median (band: interquartile range)
-0.4-0.20.00.20.40.370 bps0.345 bps0.3110 bps0.2620 bps
Show the numbers
One-way costDefault SharpeGrid medianGrid 25th pctGrid 75th pct
0 bps0.370.200.110.31
5 bps0.340.12-0.010.23
10 bps0.310.02-0.130.17
20 bps0.26-0.11-0.400.08

Execution lag. Trading two days after the signal instead of one takes the net Sharpe from 0.34 to 0.28 (gross 0.37 to 0.31).

In sample, out of sample.

In short: choosing the lookback on data up to 2012 would have picked the same twelve months, and it held up from 2013 on.

The test. Only the lookback is chosen, on net Sharpe up to 31 December 2012, and then measured from 1 January 2013. The selection picks 252 days, the pre-set value, so here tuning cost nothing: the out-of-sample Sharpe of the selected lookback is 0.38, the same as the default's.

Net Sharpe by lookback, in and out of sample

  • In sample (to 2012)
  • Out of sample (2013 on)
-0.200.000.200.4063d126d189d252d
Show the numbers
LookbackIn sampleOut of sampleChangeSelectedA priori
63 days0.18-0.21-0.39
126 days0.270.07-0.19
189 days-0.010.190.20
252 days0.290.380.08yesyes

Why selection is still risky. The 63-day lookback, 0.18 in sample, is −0.21 out of sample, and the 126-day one falls from 0.27 to 0.07. The in-sample numbers are computed blind to the later returns, and a test proves it.

Where the return came from.

In short: the return was uneven: strong before 2008 and after 2020, negative from 2014 to 2019, and it lost money in stressed markets.

By period. The net Sharpe by calendar block is 0.52 (2001–2007), 0.21 (2008–2013), −0.23 (2014–2019) and 0.80 (2020 on); the long-only basket's are 1.32, 0.36, 0.06 and 1.04. 16 of 26 calendar years were positive net. The best was 2025 at +24.60% and the worst 2016 at −21.62%, the year the 2014–2016 commodity bear market reversed.

Calendar-year returns and block Sharpe ratios

  • Strategy (net)
  • EW long-only (net)
-20%0%20%40%2001200520092013201720212025

Net Sharpe by calendar block

0.000.501.002000-20072008-20132014-20192020-present
Show the numbers
YearStrategy (net)EW long-only (net)
20012.92%-9.73%
20022.61%33.92%
20031.15%20.74%
20045.90%12.90%
20057.32%31.10%
200611.74%15.25%
20071.70%31.49%
2008-0.06%-21.61%
2009-2.32%43.12%
201014.65%40.76%
2011-5.33%-6.89%
2012-7.51%2.60%
201313.24%-9.68%
201417.06%-12.24%
20155.85%-14.08%
2016-21.62%20.65%
2017-4.98%5.17%
2018-2.26%-6.14%
2019-8.03%11.62%
202010.83%24.73%
202119.51%31.99%
20225.05%11.29%
2023-3.13%-5.61%
2024-1.24%10.62%
202524.60%15.65%
20264.26%27.51%

Over time. The rolling three-year net Sharpe is positive in 78.7% of windows, from −1.10 in the window ending January 2019 to 1.27 in the window ending March 2022.

Rolling three-year Sharpe ratio

  • Strategy (net)
  • EW long-only (net)
-1.000.001.00200420082012201620202024
Show the numbers
Year endStrategy (net)EW long-only (net)
20040.411.50
20050.431.39
20060.731.15
20070.681.65
20080.430.28
20090.040.67
20100.350.73
20110.231.15
20120.040.66
20130.03-0.18
20140.59-0.44
20151.07-1.01
2016-0.01-0.22
2017-0.640.23
2018-0.930.65
2019-0.390.44
20200.050.69
20210.641.37
20221.011.18
20230.700.77
20240.070.36
20250.640.60
20260.751.19

Calm versus stress, with hindsight. Call a day "stressed" when the basket's 60-day volatility is above its full-sample 75th percentile, a threshold known only after the fact, so this describes the past rather than giving a tradable rule. The strategy made 6.06% a year (Sharpe 0.60) on the 76% of calm days and lost 5.54% a year (Sharpe −0.48) on the 24% of stressed days, while the basket made 12.58% and 4.10%. It did not earn its keep in commodity crises, the opposite of the "crisis alpha" trend-following is often sold on: with monthly rebalancing and a twelve-month lookback it is slow to turn, and 2020 and 2022 both reversed inside a month.

Eight macro episodes.

The strategy earns when a shock extends a trend the twelve-month signal has had time to follow (oil collapse, COVID in March and April, tariffs 2025). It loses when a shock reverses that trend (2016, Hormuz). It survives fast crashes through smaller size, not direction (2008, January 2026).

EpisodeWindowNet exposure going inStrategy, netVol-targeted basketBCOM
2008 crisis1 Jul 2008 – 27 Feb 2009+0.62×−7.9%−17.9%−54.5%
Oil collapse20 Jun 2014 – 20 Jan 2016+0.13×, −0.85× by Sep 2014+26.9%−32.9%−46.5%
2016 reversal21 Jan – 30 Dec 2016−0.77×−24.3%+21.3%+20.1%
COVID2 Jan – 30 Apr 2020+1.27×+5.8%−21.3%−24.7%
Ukraine1 Feb – 30 Jun 2022+0.55×+7.6%+6.4%+8.5%
Tariffs 20252 Jan – 5 Aug 2025−0.05×+11.5%+1.9%+1.6%
Metals blow-off2 Jan – 6 Feb 2026−0.14×+2.7%+4.9%+7.5%
Hormuz2 – 31 Mar 2026+0.06×−5.3%+3.3%+11.2%

Returns are compounded over each window; net exposure is the book's net leverage on the first day of the window.

Read more

What the book looked like.

In short: the book was net long about as often as net short, and it never came close to its leverage cap.

Gross and net leverage, month by month

Gross leverage averaged 1.10× and peaked at 2.23×, so the 3× cap never bound on a single day. Net leverage swings between about -1.4× and +1.3× and crosses zero often: the book is net long about as often as net short, which is why the roll-yield flattery of the long-only basket reaches it only in part.

  • Gross leverage, sum of |weights|
  • Net leverage, longs minus shorts
-2.0×-1.0×0.0×1.0×2.0×3.0×Cap 3×, never reached200420082012201620202024

Month-end values, the state of the book after each monthly rebalance.

  • Instruments long
  • Instruments short
1050510200420082012201620202024
Show the numbers
Year endGrossNetLongShort
20010.88×-0.49×210
20021.13×1.02×121
20030.82×0.58×112
20041.11×0.07×85
20051.09×0.77×112
20061.17×0.68×103
20070.75×0.43×93
20080.37×-0.25×211
20090.93×0.65×112
20100.52×0.48×121
20110.80×0.14×76
20121.17×0.26×76
20131.91×-0.12×58
20140.91×-0.49×310
20151.13×-0.90×112
20161.23×0.66×103
20171.86×0.60×85
20181.12×-0.56×49
20191.46×0.45×94
20201.08×0.69×112
20210.81×0.60×121
20221.23×0.24×76
20231.59×0.17×67
20241.22×-0.10×67
20251.22×0.30×94
20260.97×0.53×103

Is it luck?

In short: taken alone, the result looks real; counted against all 192 configurations tried, it cannot be told apart from luck.

On its own. Net of costs, the Sharpe ratio of 0.34 has a t-statistic of 1.71 over 6,410 days, a 95% block-bootstrap interval of −0.04 to 0.72, and a Probabilistic Sharpe Ratio of 0.957: a 95.7% chance the true Sharpe is above zero, if this were the only strategy tested.

Counting every trial. It was not: 192 configurations were evaluated. Under the Bailey and López de Prado correction, the best of 192 zero-skill variants with the spread seen in the grid (a standard deviation of 0.156) would be expected to reach a Sharpe of 0.43. That is the hurdle. The default's 0.34 is below it, and the Deflated Sharpe Ratio is 0.324 net (0.372 gross): a 32% chance the result beats the luckiest of 192 null strategies, even though the default was fixed before the grid was run.

What tuning would have cost. Nothing here, by coincidence: the in-sample winner is the pre-set lookback. Had the test picked the runner-up, 126 days, the out-of-sample Sharpe would have been 0.07 instead of 0.38.

The honest summary. Twelve-month commodity trend delivered a small positive Sharpe after costs over 25 years. That is consistent with the published literature rather than a discovery in this dataset, and the evidence from one basket is too weak to rule out luck.

Limitations.

In short: free data and simple trading assumptions. Each one is stated here, and most can be swapped out.

  • Roll gaps. The prices are unadjusted front-month settlements, so every contract roll shows up as a price move and the roll yield is never paid. That flatters long positions in markets that were mostly in contango, which is why the long-only basket shows 10.48% a year and the rolling index 0.88%. A back-adjusted series from a paid vendor can be dropped in without touching the engine.
  • Negative prices and clipping. WTI's −$37.63 settlement on 20 April 2020 is handled by dividing by the absolute previous price and clipping daily returns to ±50%. Two days were clipped, both logged. The rule also tames roll gaps and bad prints, at the cost of understating the two most extreme days in the sample.
  • Gap filling. Gaps of up to 5 days get a zero return (0.21% to 0.54% of each instrument's days); longer gaps drop the instrument until data resumes. One 20-day live cattle gap passes the quality gate but not the fill limit, so 20 instrument-days carry a position but no return.
  • Universe choice. The 14 futures were picked knowing they are liquid today. Within the basket there is no survivorship bias, because the list was fixed before any backtest and platinum was excluded on data quality alone, but a desk in 2001 would not have known which contracts would stay liquid.
  • Execution. No intraday data, bid/ask spread, margin or financing: the 5 bps is a flat one-way charge, the same for crude oil and live cattle. Trading at the signal's own close is slightly optimistic; the two-day lag shows what one more day costs. Weights are held constant between rebalances rather than drifting with price.
  • The index benchmark. ^BCOM has 18 missing prints in the window and ends on 17 July 2026, 36 trading days before the snapshot; its statistics cover its own 6,356 days.
  • One snapshot. Yahoo Finance revises history. The committed snapshot makes the numbers reproducible, not permanent.

Reproduce.

First-time setup is in SETUP.md. Day to day:

make setup        # create the environment with uv
make lint test    # ruff + pytest
make all          # panel -> backtest -> benchmarks -> metrics -> robustness -> figures -> report
make notebook     # execute notebooks/strategy.ipynb headless

make all reads the committed snapshot in data/, rewrites results/ and figures/, and injects the metrics table into the README; two runs produce byte-identical files. Only make data touches the network. The robustness grid is cached in results/grid.parquet, keyed by a fingerprint of the configuration and the data, so a changed parameter re-runs only the trials it affects; delete the cache after a code change.