Monday, January 9, 2012

Cherrypicker's guide to station trends

Cherrypicker's guide to station trends

A while ago I posted a cherrypicker's guide to global surface temperature trends. This was partly in response to an outburst of the popular activity of selecting short periods where the trend could be seen as small or even negative. The idea was to embed this in a set of displayed results where you could get a broader picture of where such trends might be found, and how significant the regions were

Another popular activity is selecting stations which fail to show recent warming. So I've presented here a different kind of plot which shows all the GHCN stations on a world map, with shading to indicate the trend over the last 30, 45 or 60 years (you can choose). It derives from the plot I posted for November temperatures. It takes advantage of HTML 5 linear color shading, and uses a triangular mesh. Each station has a color corresponding to its trend for the chosen period; although the colors can vary locally, the station neighborhood itself should have the correct color. Note that there is no spatial averaging (except for the shading); the individual station trends determine the coloring.

One result that I found interesting is that while there are patchwork regions, eg USA, there are also large regions with fairly uniform trends, particularly the ocean.

So here's the plot. It is interactive - you can rearrange it, magnify, show the stations, click to see station detail and numbers etc. Use Ctrl+. Ctrl- to get it the right size for your screen. The mechanics are explained below.










your browser does not support the canvas tag


Click on this map to orient the world plot.




Show Stations
Show Mesh
Magnification
2×
4×
Trend period
Station





















































How it works

More details here. The flat map at top right is your navigator. If you click a point in that, the sphere will rotate so that point appears in the centre. The buttons below allow modification. Set what you want, and press refresh. You can show stations, and the mesh, and magnify 2×, 4×, or 8× (by setting both). You can click again to unset (and press refresh). Then you can click in the sphere. At the bottom on the right, the nearest station name and anomaly will appear. You may want to have stations displayed here. The selection menu chooses the period; if you change the period, the plot changes without need for refresh.

How the trends are calculated.

Calculating station trends is not trivial, because of missing values and seasonal variation. Obviously missing winter values at one end will bias the trend. A reasonable fix is to subtract the mean for each month and work with anomalies. But the means don't correspond exactly to the same period. I used a weighted least squares method similar to that used in TempLS. The weighting simply has unit value for months with readings, zero without. The model is xmy  ~  Lm  +  Tr  Jmy where x are the station readings, L the monthly offsets, Tr the trend, and J a linear progression of months, in century units. The suffixes m for month, y for year. This is fitted by least squares. The resulting formula is similar to OLS. If we now say that J has zero values for missing x, and I is a similar vector which is 1 mostly, but zero where x is missing, then the OLS trend formula would be
Tr = f(x) / f(J)  where   f(x) = S(Jx) - S(J) S(x) / S(I)
where S represents summation over all month/year. Denoting Sy as the process of summing over individual months, and Sm summing the resulting 12 sums, the formula from the above fit is:
Tr = f(x) / f(J); f(x) = S(Jx) - Sm( Sy(J) Sy(x) / Sy(I))

Data issues.

The data sets associated with these plots are getting larger, so attention to download time is needed. I'd like to be able to use gzip compression, but neither of the data stores I currently use support that. I have to send the data as text - basically Javascript assigns - so I use various tricks to get the text size down. I multiply by 100, say, to get rid of decimal points. I usually convert data to differences to make the numbers smaller. In fact, the biggest data item here is the world map. But potentially another big one is the triangle mesh, and there I had to make some compromises. I don't want to send a different mesh for each trend period, but if I send a mesh with all points, then in any one period, some stations will be missing. I dealt with this by using an interpolated value for coloring purposes. That's OK - the shading otherwise uses linear interpolation. But this isn't quite linear, and could look odd at times, though I haven't noticed anything. The missing (interpolated) stations don't appear when stations are shown, and are not reported when station values are produced by clicking. Anyway, the datafile size is now about 360 Kb, which is manageable. I'm looking out for better ways because I have ambitions that involve transmitting the whole TempLS dataset.

Notes


You may see a few ocean stations appearing on land. The reason is that I artificially create ststions at the centre of each 4x4 deg cell. If there is enough sea in the cell for HADSST to report a SST value, that will be assigned to that central point, even if it is on land.


Note that the color scheme suggests cooling, but most of the blue range is actually positive (though smaller) trend.


Stations are included in the trend analysis if they have at least 80% of months reporting within the range.



Saturday, December 24, 2011

Merry Christmas - and a new gallery

It's time for November temperatures with TempLS. The headline number is a cooling - from 0.48°C to 0.36°C. I'll show the usual comparative plot below.

But what I really want to talk about is a new style of presentation. The last few posts have tracked my learning curve with Javascript; now I'm coupling it with the canvas feature of HTML 5. This means I can do client-side graphics - much more flexible and interactive

What this means for November GHCN temperatures is that I can show the anomalies directly - without cell aggregation or smoothing with orthogonal functions. This is done by a triangular mesh and HTML5's neat linear color gradient function. Every station has it's anomaly directly represented with the correct color.

I found this very interesting, as it shows graphically how correlated the anomalies are. Most of the color picture is actually quite smooth. There are exceptions, and because these can be associated with large triangles, it gives an exaggerated effect there. But for the most part, large scale patterns show through well.

So here's the plot of November average temperature anomalies, in °C. It is of course interactive - you can rearrange it, magnify, show the stations, click to see station detail and numbers etc. Use Ctrl+. Ctrl- to get it the right size for your screen. The mechanics are explained below the jump.







How it works

The flat map at top right is your navigator. If you click a point in that, the sphere will rotate so that point appears in the centre. The buttons below allow modification. Set what you want, and press refresh. You can show stations, and the mesh, and magnify 2×, 4×, or 8× (by setting both). You can click again to unset (and press refresh).

Then you can click in the sphere. At the bottom on the right, the nearest station name and anomaly will appear. You may want to have stations displayed here. You'll see two faint numbers next to "stations". This indicates how much your clicked missed the station by (in pixels). It's not really a test of your mousing, but of my getting the alignment right (fiddly).

I'm continuing to work on the shading. The HTML5 function is good, but it works by RGB linear interpolation. The rainbow scheme that I use isn't linear (linear schemes are monochromatic and boring), so they get out of alignment. This sometimes means that one of the corners of the triangle does not get quite the right color. That can happen when there is a lot of change within a triangle.

Comparative plot of recent months, and the usual spherical harmonics fit.





and the Spherical Harmonics map



Previous Months

October
September
August

More data and plots

Tuesday, December 20, 2011

November GISS is out - down 0.07°C from October

The other surface indices were in notable unison. TempLS was down by 0.124°C, NOAA by 0.13°C and HADCrut by 0.122°C. Satellites showed less change. Here's the plot:


I had been using the GISS index based on V2 of GHCN, but that was discontinued this month. This caused a few days delay as my script, looking at the V2 file, said there was no change. There doesn't seem to be any great discontinuity caused by the change. Of course I'll be using the V3 version in the future.

Below the jump I'll show the comparison of the GISS and TempLS spatial distributions. This month I did another much more detailed spatial distribution based directly on station readings.



Here is the GISS plot of temperature distribution for November 2011:




And here is the TempLS version, using the GISS base years and levels.colors. I use a standard scale, and this is the first time I have overrun - the white patch over the Caucasus. I was reassured to find that GISS also used it's extreme color there. I did the map fairly this month (about 8th) but it still works fairly well.

Previous Months

October
September
August

More data and plots


Monday, December 19, 2011

Significant trends in Foster/Rahmstorf

Having recently finished a post on trends in unadjusted temperature indices, I see that Tamino has posted his code and results for the indices after adjustment for known exogenous effects.

This is of great interest to the kind of study I was doing. There the variations were assumed random, and assessed for significance on that basis. But of course we don't know they are random - it's just an model in the absence of better information. F&R have used more information, so I want to see what the effect is.

First a review of the methods. Some posts starting here looked at the pattern of temperature trends you could create with all possible start and end points over a period. Then I looked at how allowance for statistical significance changed the picture, and then at how a similar picture could be drawn of upper and lower CI's.

I want to show principally the latter analysis. Here's an example which will be enlarged later:



On the left you see the trends marked in color. The x-axis shows the end year of the trend period; the y-axis shows the start. The faint white lines at 45° show constant trend period, shown on the right axis.

On the right you see, in this case, the lower bound trends. That is the highest trend which allows you to say that the observed trend is significantly greater, at 95% confidence. It gives a cool side check to the trend. You can take a value, look up its color, and say that where you see that color or redder, you know the trend significantly exceeds that value.

Next I'll show the plot for all 5 indices used by Foster/Rahmstorf. This comes with the Javascript gadgetry I developed in previous posts. You can click on any point, and on the right you'll see printed the corresponding period and trends. On the corresponding time series plot, the red and blue balls will jump into position to show the trend. On that plot, there are controls that let you move the balls around to different locations. Below the graph, there are a set of radio button controls which allow you to switch the plot to any of the five datasets (giss,noaa,cru,rss,uah) used by Foster and Rahmstorf.













 giss
 ncdc cru
 rss uah




Now the lower bound plot. It shows that trend which is less than the observed trend, but is the highest of those for which the difference from the observed is significant. In most plots, for the longer periods, the color corresponds to about 1.3°C, so the observed (adjusted) trend is significantly higher than this.









giss
ncdc
cru
rss
uah

Now the upper bound plot, converse of the above. It shows that trend which is greater than the observed trend, but is the least of those for which the difference from the observed is significant. In most plots, for the longer periods, the color corresponds to about 1.8°C, so the observed (adjusted) trend is significantly lower than this.











giss
ncdc
cru
rss
uah