Image Credit: Climate Data Blog
By Richard Linsley Hood – Edited by Just The Facts
The goal of this crowdsourcing thread is to present a 12 month/365 day Cascaded Triple Running Mean (CTRM) filter, inform readers of its basis and value, and gather your input on how I can improve and develop it. A 12 month/365 day CTRM filter completely removes the annual ‘cycle’, as the CTRM is a near Gaussian low pass filter. In fact it is slightly better than Gaussian in that it completely removes the 12 month ‘cycle’ whereas true Gaussian leaves a small residual of that still in the data. This new tool is an attempt to produce a more accurate treatment of climate data and see what new perspectives, if any, it uncovers. This tool builds on the good work by Greg Goodman, with Vaughan Pratt’s valuable input, on this thread on Climate Etc.
Before we get too far into this, let me explain some of the terminology that will be used in this article:
—————-
Filter:
“In signal processing, a filter is a device or process that removes from a signal some unwanted component or feature. Filtering is a class of signal processing, the defining feature of filters being the complete or partial suppression of some aspect of the signal. Most often, this means removing some frequencies and not others in order to suppress interfering signals and reduce background noise.” Wikipedia.
Gaussian Filter:
A Gaussian Filter is probably the ideal filter in time domain terms. That is, if you consider the graphs you are looking at are like the ones displayed on an oscilloscope, then a Gaussian filter is the one that adds the least amount of distortions to the signal.
Full Kernel Filter:
Indicates that the output of the filter will not change when new data is added (except to extend the existing plot). It does not extend up to the ends of the data available, because the output is in the centre of the input range. This is its biggest limitation.
Low Pass Filter:
A low pass filter is one which removes the high frequency components in a signal. One of its most common usages is in anti-aliasing filters for conditioning signals prior to analog-to-digital conversion. Daily, Monthly and Annual averages are low pass filters also.
Cascaded:
A cascade is where you feed the output of the first stage into the input of the next stage and so on. In a spreadsheet implementation of a CTRM you can produce a single average column in the normal way and then use that column as an input to create the next output column and so on. The value of the inter-stage multiplier/divider is very important. It should be set to 1.2067. This is the precise value that makes the CTRM into a near Gaussian filter. It gives values of 12, 10 and 8 months for the three stages in an Annual filter for example.
Triple Running Mean:
The simplest method to remove high frequencies or smooth data is to use moving averages, also referred to as running means. A running mean filter is the standard ‘average’ that is most commonly used in Climate work. On its own it is a very bad form of filter and produces a lot of arithmetic artefacts. Adding three of those ‘back to back’ in a cascade, however, allows for a much higher quality filter that is also very easy to implement. It just needs two more stages than are normally used.
—————
With all of this in mind, a CTRM filter, used either at 365 days (if we have that resolution of data available) or 12 months in length with the most common data sets, will completely remove the Annual cycle while retaining the underlying monthly sampling frequency in the output. In fact it is even better than that, as it does not matter if the data used has been normalised already or not. A CTRM filter will produce the same output on either raw or normalised data, with only a small offset in order to address whatever the ‘Normal’ period chosen by the data provider. There are no added distortions of any sort from the filter.
Let’s take a look at at what this generates in practice.The following are UAH Anomalies from 1979 to Present with an Annual CTRM applied:
Fig 1: UAH data with an Annual CTRM filter
Note that I have just plotted the data points. The CTRM filter has removed the ‘visual noise’ that a month to month variability causes. This is very similar to the 12 or 13 month single running mean that is often used, however it is more accurate as the mathematical errors produced by those simple running means are removed. Additionally, the higher frequencies are completely removed while all the lower frequencies are left completely intact.
The following are HadCRUT4 Anomalies from 1850 to Present with an Annual CTRM applied:
Fig 2: HadCRUT4 data with an Annual CTRM filter
Note again that all the higher frequencies have been removed and the lower frequencies are all displayed without distortions or noise.
There is a small issue with these CTRM filters in that CTRMs are ‘full kernel’ filters as mentioned above, meaning their outputs will not change when new data is added (except to extend the existing plot). However, because the output is in the middle of the input data, they do not extend up to the ends of the data available as can be seen above. In order to overcome this issue, some additional work will be required.
The basic principles of filters work over all timescales, thus we do not need to constrain ourselves to an Annual filter. We are, after all, trying to determine how this complex load that is the Earth reacts to the constantly varying surface input and surface reflection/absorption with very long timescale storage and release systems including phase change, mass transport and the like. If this were some giant mechanical structure slowly vibrating away we would run low pass filters with much longer time constants to see what was down in the sub-harmonics. So let’s do just that for Climate.
When I applied a standard time/energy low pass filter sweep against the data I noticed that there is a sweet spot around 12-20 years where the output changes very little. This looks like it may well be a good stop/pass band binary chop point. So I choose 15 years as the roll off point to see what happens. Remember this is a standard low pass/band-pass filter, similar to the one that splits telephone from broadband to connect to the Internet. Using this approach, all frequencies of any period above 15 years are fully preserved in the output and all frequencies below that point are completely removed.
The following are HadCRUT4 Anomalies from 1850 to Present with a 15 CTRM and a 75 year single mean applied:
Fig 3: HadCRUT4 with additional greater than 15 year low pass. Greater than 75 year low pass filter included to remove the red trace discovered by the first pass.
Now, when reviewing the plot above some have claimed that this is a curve fitting or a ‘cycle mania’ exercise. However, the data hasn’t been fit to anything, I just applied a filter. Then out pops some wriggle in that plot which the data draws all on its own at around ~60 years. It’s the data what done it – not me! If you see any ‘cycle’ in graph, then that’s your perception. What you can’t do is say the wriggle is not there. That’s what the DATA says is there.
Note that the extra ‘greater than 75 years’ single running mean is included to remove the discovered ~60 year line, as one would normally do to get whatever residual is left. Only a single stage running mean can be used as the data available is too short for a full triple cascaded set. The UAH and RSS data series are too short to run a full greater than 15 year triple cascade pass on them, but it is possible to do a greater than 7.5 year which I’ll leave for a future exercise.
And that Full Kernel problem? We can add a Savitzky-Golay filter to the set, which is the Engineering equivalent of LOWESS in Statistics, so should not meet too much resistance from statisticians (want to bet?).
Fig 4: HadCRUT4 with additional S-G projections to observe near term future trends
We can verify that the parameters chosen are correct because the line closely follows the full kernel filter if that is used as a training/verification guide. The latest part of the line should not be considered an absolute guide to the future. Like LOWESS, S-G will ‘whip’ around on new data like a caterpillar searching for a new leaf. However, it tends to follow a similar trajectory, at least until it runs into a tree. While this only a basic predictive tool, which estimates that the future will be like the recent past, the tool estimates that we are over a local peak and headed downwards…
And there we have it. A simple data treatment for the various temperature data sets, a high quality filter that removes the noise and helps us to see the bigger picture. Something to test the various claims made as to how the climate system works. Want to compare it against CO2. Go for it. Want to check SO2. Again fine. Volcanoes? Be my guest. Here is a spreadsheet containing UAH and a Annual CTRM and R code for a simple RSS graph. Please just don’t complain if the results from the data don’t meet your expectations. This is just data and summaries of the data. Occam’s Razor for a temperature series. Very simple, but it should be very revealing.
Now the question is how I can improve it. Do you see any flaws in the methodology or tool I’ve developed? Do you know how I can make it more accurate, more effective or more accessible? What other data sets do you think might be good candidates for a CTRM filter? Are there any particular combinations of data sets that you would like to see? You may have noted the 15 year CTRM combining UAH, RSS, HadCRUT and GISS at the head of this article. I have been developing various options at my new Climate Data Blog and based upon your input on this thread, I am planning a follow up article that will delve into some combinations of data sets, some of their similarities and some of their differences.
About the Author: Richard Linsley Hood holds an MSc in System Design and has been working as a ‘Practicing Logician’ (aka Computer Geek) to look at signals, images and the modelling of things in general inside computers for over 40 years now. This is his first venture into Climate Science and temperature analysis.





george e. smith says:
March 17, 2014 at 2:05 am
“Filters throw away information. The raw data, is the most information you can ever have. Filters simply delude one into believing that something else is happening; other that what the measured sampled data values tell.”
Not true. Low pass/High pass filters/splitters always add together to produce the whole of the input signal. No data is ever ‘lost’. You just get to look at a sub-section of it.
If you want the High pass values do a 1-x (i.e. take the output from the 15 year low pass and subtract it from the input signal making sure you get the phase right – which will be a challenge for the 12 month) and you will get that data instead.
Monckton of Brenchley says:
March 17, 2014 at 2:45 am
“I am very grateful to RichardLH for his courteous answers to my questions. ”
No problem.
“But I should like more detail on why the particular function he has chosen is any better at telling us what is happening in the data than the linear trends used by the IPCC etc.”
A linear trend is the ultimate in removing useful information.
Decide for yourself if this treatment of the UAH data for Land, Ocean and Combined provides a better insight into what happened in the last 34 years or a set of OLS straight lines.
http://climatedatablog.files.wordpress.com/2014/02/uah-global.png
“So, what does your curve tell us about global mean surface temperature that we do not already know?”
That things are much more naturally cyclic than the IPCC would like to concede. The biggest thing that the IPPC try to avoid is “how much of all of this is natural?”
Willis Eschenbach says:
March 17, 2014 at 2:52 am
“Once again, the CTRM filter underneath the gaussian filter is scarcely visible … so I repeat my question. Why do we need a new filter that is indistiguishable from a gaussian filter?”
Try that again without the full data points to make the difference almost two flat lines and you will see.
cd says:
March 17, 2014 at 3:04 am
“Nice concise post. I have three questions – sorry.”
Thanks and no problem.
“1) Are the cascade filters based on recursive operations using some basis functions? If yes, then is this not akin to curve fitting? I’ve probably misunderstood but I think you’ve taken issue with this before.”
No – this is most definitely NOT curve fitting. It is just a high quality low pass filter that is simple to implement. Much purer mathematically than the single running means often used.
“2) In the field I work in we tend to use the Butterworth filter extensively; but in light of the recent post on “signal stationarity” in WUWT, does such an approach seem inappropriate if the composed data series is the sum of many non-stationary signals. I suspect that there will be major issues with significant localised phase shifts (something I understand to be a problem with the Butterworth filter even with “perfect” data sets).”
This is pure Gaussian – or even slightly better than Gaussian in that it completely removes the 12 month ‘cycle’ without any additional distortions.
“3) Finally, for the purposes of quant operations, is the filtered data any use beyond signal analysis? For example, even if one uses the best filtering method, does the resulting processed series not take with it significant bias: when one tries to statistically quantity something like correlation between two filtered data sets. This seems a little open ended I know, but you see this type of analysis all the time.”
Well the option exists to do straight comparisons with other similarly filtered signals to see what differences, co-incidence exists without moving to statistics. You know what they say about statisticians 🙂
steveta_uk says:
March 17, 2014 at 3:12 am
“Richard, can you design a filter to remove comments from the people who don’t believe the data in the first place? Why they bother commenting is a mystery to me ;(”
Beyond my capabilities I’m afraid.
D. Cohen says:
March 17, 2014 at 3:33 am
“What happens when you apply the same filters to the sunspot data over the last 150 or so years?”
I haven’t looked at the sunspot data yet.
tadchem says:
March 17, 2014 at 4:18 am
“I have used Fourier analysis successfully to detect periodic and pseudo-periodic effects on data.”
FFTs suffer great problems with noisy data. Especially at the longer wavelengths as you approach the data series length. Given the noise in the temperature data series I would be very cautious with anything that has less than about 5 (or better still 10) cycles in it when using FFTs..
davidmhoffer says:
March 17, 2014 at 4:19 am
“How sad that both warmists and skeptics have become so obsessed with the measurement of average temperature and the analysis of it that we’ve completely forgotten what the original theory was that we were trying to prove or disprove. The theory is that doubling of CO2 increases downward LW by 3.7 w/m2. So, to determine if the theory is correct or not, we run right out and analyze a metric that has no linear relationship to w/m2 at all, and rationalize that somehow this is OK because the earth integrates it out for us.”
I notice that you kinda skipped the part where I refuted your claims. Matter integrates incoming and outgoing power, continuous and pulsed, and shows the result as temperature. Or are you claiming different?
“pfffffft.”
Indeed.
Richard, just used your woodfortrees temperature graph and changed to ssn:
http://www.woodfortrees.org/plot/sidc-ssn/plot/sidc-ssn/mean:220/mean:174/mean:144/plot/sidc-ssn/mean:720
RichardLH;
I notice that you kinda skipped the part where I refuted your claims. Matter integrates incoming and outgoing power, continuous and pulsed, and shows the result as temperature. Or are you claiming different?
>>>>>>>>>>>>>>>>>>
On a long enough time scale maybe. On the time scale you are using here, absolutely not.
A perturbation to the system which changes the transport of energy from tropics to poles will result in a smaller change in temperature to the tropics and a larger one in the arctic regions. Average the temperatures out on a time scale too short to integrate them out and you get a result that is over represented by changes to cold temperatures and under represented by changes to warm temperatures.
We’re talking about a perturbation to the system that is decades to centuries long by the most conservative estimates. So no, you cannot rely on matter to integrate the result for you on time scales that you are using.
davidmhoffer says:
March 17, 2014 at 4:52 am
“On a long enough time scale maybe. On the time scale you are using here, absolutely not.”
On any time scale from milliseconds (or below) on upwards actually. Individual chunks of matter do this all the time. Which was the point I was refuting and you keep dodging.
“A perturbation to the system which changes the transport of energy from tropics to poles will result in a smaller change in temperature to the tropics and a larger one in the arctic regions. Average the temperatures out on a time scale too short to integrate them out and you get a result that is over represented by changes to cold temperatures and under represented by changes to warm temperatures.”
I agree that to get to a steady state through mass transport with the varying inputs we have will take a very long time and probably be cyclic. ~60 years would fall into that category. The greater than 75 years would be another.
“We’re talking about a perturbation to the system that is decades to centuries long by the most conservative estimates. So no, you cannot rely on matter to integrate the result for you on time scales that you are using.”
Well as that is how it does it I am not sure you are supporting your case.
Edim says:
March 17, 2014 at 4:51 am
“Richard, just used your woodfortrees temperature graph and changed to ssn:
http://www.woodfortrees.org/plot/sidc-ssn/plot/sidc-ssn/mean:220/mean:174/mean:144/plot/sidc-ssn/mean:720”
That would have been Greg’s graph with those values.
I would have used
http://www.woodfortrees.org/plot/sidc-ssn/plot/sidc-ssn/mean:360/mean:298/mean:204
which does raise some interesting questions.
Richard,
John Linsley Hood was one of the greatest analogue electronic design engineers the UK has ever produced. I wish I’d known him. I spent a lot of my time at university back in the 80’s building his designs when I should have been using my project budget on, well, my project.
I am sad he’s gone, but I don’t think he’ll be forgotten.
Edim says:
March 17, 2014 at 4:51 am
And compared it thus
http://www.woodfortrees.org/plot/sidc-ssn/plot/sidc-ssn/mean:360/mean:298/mean:204/plot/hadcrut4gl/mean:360/mean:298/mean:204/scale:100/offset:75
RichardLH
Thanks for your reply.
With regard to your answer to my question 2. I appreciate that the Butterworth filter (frequency domain) can be seen as an approximation of a Gaussian convolution given complementary parameters. And I’m not talking about the relative merits of either. I guess what I’m really asking is: Is there a problem in designing a filter based on spectral profile (“hard” approach ), as opposed to eye-balling the parameter in the host domain (“soft” approach), if the composed signal (the raw data) is the sum of many non-stationary signals?
In my field of study, the Butterworth is effectively a passband filter where the higher frequencies are typically removed, according to the filter parameters which are determine from the series’ spectral profile. But the recent discussion, with respect to signal stationarity, would deem such an approach foolhardy rather than proper, and yet it’s used extensively.
I was interested in hearing your views on this if you have time.
I hope it doesn’t seem off topic.
RichardLH;
Well as that is how it does it I am not sure you are supporting your case.
>>>>>>>>>>>>
Doubling of CO2 changes the effective black body temperature of earth by precisely zero. There is your integration. Yet it increases downward LW flux. The latter is not integrated on the time scales that you are using, and you can’t measure it as an average by measuring and averaging temperature instead because temperature varies with the 4th root of P.
Steve Taylor says:
March 17, 2014 at 5:15 am
“John Linsley Hood was one of the greatest analogue electronic design engineers the UK has ever produced. I wish I’d known him. I spent a lot of my time at university back in the 80′s building his designs when I should have been using my project budget on, well, my project.
I am sad he’s gone, but I don’t think he’ll be forgotten.”
Between them he and my father (still alive) brought me up to be interested in engineering and science from a very early age. I doubt he will be forgotten. He used two very simple tools in his work, a precise notch [filter] and a very pure sine wave generator. Allowed him to look in great detail at the work he did with the results you saw.
EDIT; a precise notch filter
One is tempted to conclude,
“It’s the Sun stupid!”
RichardLH: But this is most definitely NOT a curve fitting exercise! Indeed this is the exact opposite.
Using a word from Willis Eschenbach’s post (the word, I am not attributing an idea to him, though I agree with his main point), what you have done is indistinguishable from curve fitting. “Filtering” is nothing more than than fitting data by a method that uses a set of basis functions, and then separating the results into two components (as said by Greg Goodman), one fit by the method and the basis functions, the other not.
If you know the noise, you can design a filter to reveal the signal. If you know the signal, you can design a filter to reveal the noise. When, as with modern temperature series, you have no claim to know either, you can fit dozens, maybe hundreds (Donoho calls the method “basis pursuit”) of filters equally well to the same data set, each claiming some superiority in some cases. With some filters, “the wiggle is there”, as you wrote; with some filters the wiggle is not there. Whether the “wiggle” is generated by an underlying process that persists and can be described by physical laws can not be determined by looking at the filtering results on the extant data..
cd says:
March 17, 2014 at 5:20 am
“I guess what I’m really asking is: Is there a problem in designing a filter based on spectral profile (“hard” approach ), as opposed to eye-balling the parameter in the host domain (“soft” approach), if the composed signal (the raw data) is the sum of many non-stationary signals?”
I guess what I am really saying is that by only making a simple 15 years low pass corner frequency choice I am not making any (or very few) assumptions about all of this and what is or is not present.
If you run a standard ‘sweep’ up the available bandwidth, then there is a ‘sweet spot’ between 12-20 years where the output doesn’t change much.
Typically that is always going to be a good choice for a binary chop point, hence the 15 year corner.
The rest is what then comes out.
Richard LH
For a future endeavor, you might find it interesting to explore the Global Warming Prediction Project. and how their automatic model results compare with your filtered data.
davidmhoffer says:
March 17, 2014 at 5:21 am
“Doubling of CO2 changes the effective black body temperature of earth by precisely zero. There is your integration. Yet it increases downward LW flux. The latter is not integrated on the time scales that you are using, and you can’t measure it as an average by measuring and averaging temperature instead because temperature varies with the 4th root of P.”
I get you don’t think that measuring temperatures or seeing how they evolve over time is a useful exercise. But you logic is faulty as to the methodology of how energy is absorbed/emitted from an object and the temperature of that object over time. IMHO.
Matthew R Marler says:
March 17, 2014 at 6:12 am
“Using a word from Willis Eschenbach’s post (the word, I am not attributing an idea to him, though I agree with his main point), what you have done is indistinguishable from curve fitting.”
It is not. Curve fitting is deciding a function and then applying it to the data. No functions were harmed in the making of these graphs. 🙂
” “Filtering” is nothing more than than fitting data by a method that uses a set of basis functions, and then separating the results into two components (as said by Greg Goodman), one fit by the method and the basis functions, the other not.”
Bandpass splitting, which is what low/high pass filters do, is more a binary choice type of exercise. No decisions are made or needed about what is or isn’t three. Only that it should be longer or shorter than the corner frequency.
“If you know the noise, you can design a filter to reveal the signal. If you know the signal, you can design a filter to reveal the noise.”
Signal = Greater than 15 years
Noise = Less than 15 years
Filter = CTRM or Gaussian
“When, as with modern temperature series, you have no claim to know either, you can fit dozens, maybe hundreds (Donoho calls the method “basis pursuit”) of filters equally well to the same data set, each claiming some superiority in some cases.”
Individual frequencies can be targeted or even groups of frequencies. That is not what is being done here. A binary chop, nothing more, nothing less.
“With some filters, “the wiggle is there”, as you wrote; with some filters the wiggle is not there. Whether the “wiggle” is generated by an underlying process that persists and can be described by physical laws can not be determined by looking at the filtering results on the extant data.”
Well whatever your logic there is something with some power in the 15 to 75 year bracket that the data says is present and needs explaining.
Edim says:
March 17, 2014 at 5:53 am
“One is tempted to conclude, “It’s the Sun stupid!””
One would need a physical method to connect one to the other in a cyclic fashion. So far nothing has made it past the required scrutiny. Those that fit the cycle seem to lack the power and vice versa.