About Math

Math

Methods and formulas. Today’s fitted centres load from this morning’s file. That is enough to take elsewhere if you want to reconstruct it.

Derived series

Dollar stocks never vote a colour. They sit on the lookback, or they become a ratio, a spread, or a rate of change. FRED units first: Fed assets and the Treasury account in millions, reverse repo in billions, Bank of Japan assets in hundreds of millions of yen.

Net liquidity
WALCL(bn) − TGA(bn) − ON RRP(bn) WALCL and TGA ÷ 1,000 from millions. GDP share votes; the stock does not.
Reserves ÷ GDP
(WRESBAL millions ÷ 1,000) ÷ nominal GDP × 100 Trailing five-year, not a fixed band.
Net liquidity ÷ GDP
net liquidity (bn) ÷ nominal GDP × 100 Trailing five-year.
Funding vs target top
(overnight funding − fed funds target top) × 100 bp. SOFR from 2018-04-02, EFFR before. Trailing five-year. High is tight.
G4 central bank assets
Fed + ECB×USD/EUR + BoJ×(100 / yen per dollar) + China FX reserves Each leg at that day’s rate, summed in $tn. Level does not vote.
Global CB assets, 12m
(G4 today − G4 ~1y ago) / |G4 ~1y ago| × 100 The G4 voter. Neutral at +5%, not zero.
Dollar, 12m change
(broad dollar today − ~1y ago) / |~1y ago| × 100 DTWEXBGS. Rising is tight for Liquidity.
Global long rates (G3)
(Bund 10y + gilt 10y + JGB 10y) / 3 Last observation carried across holidays.
Credit impulse (US)
Δ over ~1y of (TOTLL YoY %) Lookback only. Does not vote a colour.
China credit impulse
China credit/GDP today − China credit/GDP four quarters ago Lookback only. The stock votes Liquidity at half weight.
Equity risk premium
S&P earnings yield − 10-year real yield Wide = equities cheap versus duration.
Nominal − real GDP
nominal GDP YoY − real GDP YoY Story, not a ballot.
Stock–bond correlation
60-day Pearson of SPX returns vs −Δ 10-year yield Confirm / falsify, not a component vote.
Gold positioning
156-week min–max of CFTC non-commercial net % of open interest 0 least crowded, 100 most. Taxes Gold when longs are crowded.
2-year real (Rates vote)
2-year yield − core PCE YoY Built at score time. TIPS 5y and 10y vote as published.

How a print becomes a score

Each voter maps to −1…+1. Positive is the reflationary side of that component. If high is the contractionary end, the sign flips once, in the band.

band: ≤ low → −1 · mid → 0 · ≥ high → +1 · linear between

Trailing five-year (reserves ÷ GDP, net liquidity ÷ GDP, funding spread). Needs about two years or it abstains:

clip( (print − 5y mean) / sd / 2 , −1, +1 )

How scores become a component

Related prints share a ballot, then ballots average. Inside a ballot, members can be weighted.

  • Liquidity — Fed GDP shares · funding cost · commercial paper · global CBs and the dollar. Four ballots, all counted: the trim needs six.
  • Rates — real yields · nominal yields · the curve · bond vol
  • Growth — coincident × 0.5 · leading × 1.5 · surveys × 1. Coincident is halved because jobs and GDP describe the quarter that ended. When the surveys are past ±0.45 while coincident is still inside it, coincident has followed them within a quarter about two thirds of the time since 2003, against 50% on all other days — so the surveys may take the word.
  • Inflation — realized × 2 · persistence · expectations
  • Risk — credit spreads · volatility

Five or more ballots: drop the high and the low, then average. Liquidity is the one that trims. MOVE can turn Rates red, never green. If funding cost or commercial paper is ≤ −0.5, Liquidity is held at least that tight.

Then recenter and stretch so all five share one spread:

score = clip( ((raw − mean) / sd) × shared spread × scale, −1.5, +1.5 )

Green and red at ±0.45. The middle is the word. Today’s fit:

Loading…

Lookback, and when a series stops voting

1w = 7 calendar days, 2w = 14, 1m = 30, 3m = 91, 6m = 182. A series too slow to fill the window steps back whole prints instead. Monthly: one step back on 1w / 2w / 1m, three on 3m, six on 6m. Quarterly: one step back on 1w / 2w / 1m / 3m, two on 6m — so a weekly lookback on a quarterly series is still the last quarter-on-quarter change, not a flat line. Stale (does not vote): 14d daily, 21d weekly, 85d monthly, 190d quarterly.

The table lookback only colors rows and sets spark length. Chevrons, duration, credit, and in / mixed / out use the 1m turn.

Duration risk and credit risk

Soft weight 0…1, fully on at the colour line ±0.45. The six asset nets use these weights on the score, not only the word — so Neutral Risk at +0.40 is almost fully Risk-on for every net. Positive net = that risk is falling. Call at ±0.35.

The two weights are not mirrors: easeW ramps over 0.65 from −0.2, tightW over 0.25 from −0.2. A score of exactly 0.00 therefore returns easeW 0.31 and tightW 0.00. Deliberate — fear and drain must be clearly present before they price, while ample conditions are the resting state — and it tilts every net slightly toward reflation.

easeW = clip((score + 0.2) / 0.65, 0, 1) tightW = clip((−0.2 − score) / 0.25, 0, 1)

Duration (positive = duration risk falling):

−0.70 × hot inflation that is not cooling +0.65 × cold inflation +0.45 × hot-but-cooling on the 1m turn −0.55 × tight Rates +0.35 × easy Rates +0.70 × term-premium z +0.55 × 10-year real-yield z −0.25 × strong Growth × (1 − cold inflation)

Credit (positive = credit risk falling):

+0.35 × strong Growth −0.35 × soft Growth +0.35 × Risk-on −0.35 × Risk-off −0.30 if activity is rolling over on the 1m turn, +0.20 if it is firming −0.30 if high-yield spreads are widening, +0.20 if they are tightening −0.35 if US bank-credit impulse is slowing, +0.35 if it is speeding up −0.15 if China credit impulse is slowing, +0.15 if it is speeding up +0.25 × credit-spread z (wide = you are paid)

Valuation: clip((print − median) / scale, −1, +1). High-yield OAS is pinned at 4.0%. Today’s centres:

Loading…

How a class gets in / mixed / out

Each class has its own net of conditions. Most map in at +0.35 and out at −0.35. Equities 0.10 / −0.18; Crypto 0.14 / −0.24; Gold ±0.18. Credit parent 0.24 / −0.26; HY ±0.26; oil, copper, and the commodity parent 0.12 / −0.22. 5 (cash) is on the Treasuries strip and out of the parent net and the parent needle — the long end is the Treasuries call.

These cuts are not one shared scale. Each net is fitted against its own spread, and the spreads differ: the 10s and 30s nets can run to about ±3.3, the equity net to about ±1.1, the 5s net to exactly ±1. So ±0.35 is roughly a tenth of the range on the long end and about a third of it on the front end. Read a threshold against its own class, never across two.

needle = 0.72 × checklist + 0.28 × 1m turn

The 1m turn may slide the needle. It cannot flip the call. The table lookback does not enter this mix.

The archive, and how a comparable day is found

The archive is a replay: today’s rules run over 2003 to now, rebuilt from scratch each morning. It is not a record of what the app said. Scores in it are calibrated on an expanding window — each day is scored against only the days before it, so 2004 never sees 2015’s distribution. The live score uses the full-sample fit instead, which is why the two are built by different paths on purpose.

A comparable day is straight-line distance across the five component scores:

d = √( Σ (pasti − todayi)² ) over the five components

Nearest first, but no two picked days may sit within 21 days of each other, and at most 40 are kept. Without the gap rule a single quiet stretch would supply all forty and one episode would be reported as forty precedents. The set’s median distance names the match: < 0.35 close · < 0.70 loose · beyond that distant. For scale, a typical day in the archive sits about 0.57 from its own forty nearest, so “loose” is the ordinary result and not by itself a warning.

Forward returns are simple percent changes measured in trading days — 1w = 5, 2w = 10, 1m = 21, 3m = 63, 6m = 126, 12m = 252 — and equal-weighted where a class has more than one asset: Treasuries from 5s, 10s and 30s; credit from HY and IG; commodity from oil and copper. Bond and equity ETFs use adjusted close, since a coupon is most of a bond’s return. Treasury forwards are synthetic total returns built from yields (daily ≈ y/252 − D·Δy), so the grade matches the 5s / 10s / 30s the strip actually names.

Grading counts independent windows, not days. A call held for 58 straight days and graded on a one-month forward return is roughly two separate bets on one episode, not 58, because every window overlaps its neighbours. The count is greedy: take a window, skip everything it covers, take the next.