Arron Bennett, Founder of Bennett Financials

Monthly revenue in a seasonal business is almost useless on its own.

An irrigation company earns six times more in May than in January. Month-over-month growth swings from minus 50% to plus 150%. The owner looks at a chart of monthly bars and sees whatever they hoped to see.

There's a standard fix in finance called trailing twelve months, or TTM. It's a rolling twelve-month sum. In pandas it's one line. This post builds it on a small data set and shows what it reveals that the monthly numbers hide.

The problem with monthly numbers

A seasonal business has two things happening at once: the season and the trend. Monthly revenue shows you both mixed together, and the season is far bigger. A 3% change in underlying demand is invisible next to a 90% jump from March to April.

There are two common ways to remove the season:

  1. Compare with the same month last year. Better than month over month, but noisy. One large job landing in a different month can swing it ten points.
  2. Sum the last twelve months. Every window contains exactly one January, one February and so on. The season cancels out. What's left is the trend.

We'll calculate both and see how they differ.

The data

Here's a hypothetical example. Every number is made up to show the method.

A 12-person company installs and repairs lawn irrigation systems. Revenue is about $1.6 million a year. I've generated 36 months of revenue with a strong season. Underneath it, demand grows steadily for 26 months and then slips a little for 10. That slip is what we want to be able to detect.

import numpy as np import pandas as pd rng = np.random.default_rng(7) months = pd.period_range("2023-11", "2026-10", freq="M") # Share of a "normal" month. An irrigation company earns most of its year from April to October. season = {1: 0.25, 2: 0.30, 3: 0.75, 4: 1.45, 5: 1.80, 6: 1.60, 7: 1.35, 8: 1.20, 9: 1.15, 10: 1.25, 11: 0.60, 12: 0.30} # Underlying demand: grows for 26 months, then quietly slips for 10. level = np.concatenate([np.linspace(112_000, 141_000, 26), np.linspace(140_000, 128_000, 10)]) revenue = [round(l * season[m.month] * rng.normal(1, 0.04), -2) for l, m in zip(level, months)] df = pd.DataFrame({"revenue": revenue}, index=months) 

With real data you'd replace all of that with one read_csv of a monthly export from your accounting software, indexed by month.

The calculation

Five columns. Each is a single pandas call.

df["mom"] = df["revenue"].pct_change() # vs last month df["yoy"] = df["revenue"].pct_change(12) # vs same month last year df["ttm"] = df["revenue"].rolling(12).sum() # trailing twelve months df["ttm_move"] = df["ttm"].diff() # what this month added or removed df["ttm_yoy"] = df["ttm"].pct_change(12) # TTM vs TTM a year ago 

Two of those deserve a note.

ttm_move is the change in the TTM from one month to the next. It has a neat property. When the window rolls forward, it adds the newest month and drops the same month from a year earlier. So ttm_move is exactly this month's revenue minus the same month last year, in dollars. It's the year-over-year comparison expressed as money rather than a percentage.

ttm_yoy compares the current twelve-month total with the twelve-month total a year ago. This is the smoothest growth rate you can get from monthly data, and it needs 24 months of history before it produces a number.

Now print the last year, plus the peak and the seasonal shape:

pd.options.display.float_format = "{:,.0f}".format show = df.tail(12).copy() for c in ["mom", "yoy", "ttm_yoy"]: show[c] = (show[c] * 100).round(1).astype(str) + "%" print(show.to_string()) peak = df["ttm"].idxmax() print() print(f"TTM peak: {peak} ${df.loc[peak, 'ttm']:,.0f}") print(f"TTM now: {df.index[-1]} ${df['ttm'].iloc[-1]:,.0f}") print(f"Change since peak: ${df['ttm'].iloc[-1] - df.loc[peak, 'ttm']:,.0f}") share = df["revenue"].groupby(df.index.month).sum() / df["revenue"].sum() print() print("Share of the year by month:") print((share * 100).map("{:.1f}%".format).to_string()) 

The output

 revenue mom yoy ttm ttm_move ttm_yoy 2025-11 84,400 -51.8% 11.2% 1,554,100 8,500 7.5% 2025-12 42,000 -50.2% 14.4% 1,559,400 5,300 7.7% 2026-01 31,500 -25.0% -1.6% 1,558,900 -500 7.4% 2026-02 40,700 29.2% 2.0% 1,559,700 800 6.9% 2026-03 102,800 152.6% 10.9% 1,569,800 10,100 7.1% 2026-04 198,100 92.7% 5.7% 1,580,400 10,600 6.2% 2026-05 227,600 14.9% 3.0% 1,587,000 6,600 6.1% 2026-06 209,300 -8.0% 2.9% 1,592,900 5,900 6.5% 2026-07 171,200 -18.2% 1.2% 1,595,000 2,100 6.0% 2026-08 151,700 -11.4% -6.4% 1,584,600 -10,400 4.0% 2026-09 155,000 2.2% 3.3% 1,589,500 4,900 4.0% 2026-10 154,800 -0.1% -11.6% 1,569,100 -20,400 1.5% TTM peak: 2026-07 $1,595,000 TTM now: 2026-10 $1,569,100 Change since peak: $-25,900 Share of the year by month: 1 2.0% 2 2.5% 3 6.2% 4 12.1% 5 14.6% 6 13.5% 7 11.0% 8 10.0% 9 9.9% 10 10.7% 11 5.0% 12 2.5% 

Reading it

Go column by column.

mom is noise. Minus 51.8%, plus 152.6%, minus 18.2%. That's the calendar, not the business. Nothing in this column should drive a decision.

revenue tells a flattering story. May 2026 was $227,600, the biggest month in the data set. If the owner judges the year by its best month, it was a record spring.

yoy is honest but jumpy. It reads 14.4% in December, minus 1.6% in January, 10.9% in March, minus 6.4% in August, 3.3% in September and minus 11.6% in October. You can sense it getting weaker, but any single month could be explained away. December's 14.4% is also on a $42,000 month, so it's a big percentage on very little money.

ttm is the clear one. It climbs from $1,554,100 to a peak of $1,595,000 in July, then falls to $1,569,100. The business is $25,900 smaller on a twelve-month basis than it was three months ago.

ttm_yoy shows the slowdown long before the peak. Annual growth was 7.7% in December. By July it was 6.0%, while the TTM was still rising. By October it's 1.5%. Growth was fading through the whole "record" spring. The business only started shrinking in dollar terms in August, but the trend had been bending for eight months.

That's the part worth remembering. The level kept going up while the growth rate kept going down. If you only look at the level, you get the news late.

What the seasonal share is for

The last block shows what fraction of three years of revenue landed in each calendar month. April to October is about 82% of the year. January is 2%.

That table turns a monthly figure into a sanity check. If a typical May is 14.6% of the year and this May came in at $227,600, a rough annual pace is 227,600 divided by 0.146, which is about $1.56 million. Useful when you only have a few months of the current year and want to know roughly where it's heading. It's crude, because one month is one month, but it beats multiplying May by twelve.

A few practical notes

  • You need 12 months for a TTM and 24 for TTM growth. rolling(12) returns NaN until the window is full. That's correct. Don't pass min_periods=1, or early values will be partial sums that look like a collapse.
  • Check for missing months. A rolling window counts rows, not dates. If a month is absent from the index, the "twelve-month" window quietly spans thirteen. Reindex to a complete period_range first.
  • Use the same basis every month. Invoiced revenue, not cash received, and not a mix. A big deposit recorded as revenue in the wrong month will distort twelve windows in a row.
  • One-off jobs stay in the window for a year. A single large commercial install lifts the TTM when it lands and drops out exactly twelve months later, which looks like a decline. Annotate those.
  • TTM is slow by design. It won't tell you about last week. It tells you whether the last year was better than the year before it, updated monthly.

The same five lines work on any monthly series with a season in it: support tickets, sign-ups, energy use, ad spend.

The business point

Revenue is already a late signal. It tells you what happened after the leads, the quotes and the booked jobs that produced it. In this short clip I explain why I'd rather watch the numbers that come before revenue.

TTM doesn't change that. It's still built from revenue. What it does is stop the season from hiding the trend, so the late signal at least arrives clean. For the irrigation company, the next question isn't in this data set at all. It's in the booked-jobs and quote counts from spring, which would show where the slowdown began.

Further reading: