Phase and Amplitude Variation in Montreal Weather
Phase and Amplitude Variation in Montreal Weather
Phase and Amplitude Variation in Montreal Weather
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
<strong>Phase</strong> <strong>and</strong> <strong>Amplitude</strong> <strong>Variation</strong><br />
<strong>in</strong> <strong>Montreal</strong> <strong>Weather</strong><br />
Jim Ramsay<br />
McGill University
The Data<br />
• 34 years of daily temperatures, 1961-1994<br />
1994<br />
<strong>in</strong>clusive<br />
• Values are averages of daily maximum<br />
<strong>and</strong> m<strong>in</strong>imum<br />
• 12410 observations <strong>in</strong> tenths of a degree<br />
Celsius<br />
• Available for <strong>Montreal</strong> <strong>and</strong> 34 other<br />
Canadian weather stations
We know that there are two k<strong>in</strong>ds of<br />
variation <strong>in</strong> these data:<br />
1. <strong>Amplitude</strong> variation: : day-to<br />
to-day <strong>and</strong><br />
year-to<br />
to-year variation <strong>in</strong> temperature<br />
at events such as the depth of w<strong>in</strong>ter.<br />
2. <strong>Phase</strong> variation: : the tim<strong>in</strong>g of these<br />
events -- the seasons arrive early <strong>in</strong><br />
some years, <strong>and</strong> late <strong>in</strong> others.
Goals<br />
• Separate phase variation from amplitude<br />
variation by register<strong>in</strong>g the series to its<br />
strictly periodic image.<br />
• Estimate components of variation due to<br />
amplitude <strong>and</strong> phase variation.
Smooth<strong>in</strong>g<br />
The registration process requires that we<br />
smooth the data two ways:<br />
1. With an unconstra<strong>in</strong>ed smooth that<br />
removes the day-to<br />
to-day variation, but<br />
leaves longer-term variation unchanged.<br />
2. With a strictly periodic smooth that<br />
elim<strong>in</strong>ates all but strictly periodic trend.
Unconstra<strong>in</strong>ed smooth<br />
• Raw data are represented by a B-spl<strong>in</strong>eB<br />
expansion us<strong>in</strong>g 500 basis functions of<br />
order 6.<br />
• Knot about every 25 days.<br />
• The st<strong>and</strong>ard deviation of the raw data<br />
about this smooth, adjusted for degrees of<br />
freedom, is 4.30 degrees Celsius.
Periodic smooth<br />
• The basis is Fourier, with 9 basis functions<br />
judged to be enough to capture most of<br />
the strictly periodic trend for a period of<br />
one year.<br />
• The st<strong>and</strong>ard deviation of the raw about<br />
data about this smooth is 4.74 deg C.<br />
• Compare this to 4.30 deg C. for the<br />
unconstra<strong>in</strong>ed smooth.
• Plott<strong>in</strong>g the unconstra<strong>in</strong>ed B-spl<strong>in</strong>eB<br />
smooth m<strong>in</strong>us the constra<strong>in</strong>ed Fourier<br />
smooth reveals some strik<strong>in</strong>g<br />
discrepancies.<br />
• We focus on Christmas, 1989. The<br />
Ramsay’s s spent the holidays <strong>in</strong> a chalet<br />
<strong>in</strong> the Townships, <strong>and</strong> awoke to –37 deg<br />
C. No ski<strong>in</strong>g, car dead, marooned!<br />
• This temperature would still be cold <strong>in</strong><br />
mid-January, but less unusual.
Registration<br />
• Let the unconstra<strong>in</strong>ed smooth be x(t) <strong>and</strong><br />
the strictly periodic smooth be x 0 (t).<br />
• We need to estimate a nonl<strong>in</strong>ear strictly<br />
<strong>in</strong>creas<strong>in</strong>g smooth transformation of time<br />
h(t), called a warp<strong>in</strong>g function, , such that<br />
a fitt<strong>in</strong>g criterion is m<strong>in</strong>imized.
Fitt<strong>in</strong>g criterion<br />
The fitt<strong>in</strong>g criterion was the smallest<br />
eigenvalue of the matrix<br />
⎡<br />
⎢<br />
⎢<br />
⎣<br />
∫<br />
∫<br />
2<br />
x () () ()<br />
0<br />
t dt ∫x0<br />
t x ⎡⎣<br />
h t ⎤⎦<br />
dt⎤<br />
⎥<br />
() ()<br />
2<br />
x ()<br />
0<br />
t x⎡h t ⎤dt x ⎡h t ⎤dt<br />
⎥<br />
⎣ ⎦ ∫ ⎣ ⎦ ⎦<br />
This criterion measures the extent<br />
to which a plot of x[h(t)] aga<strong>in</strong>st<br />
x 0 (t) is l<strong>in</strong>ear, <strong>and</strong> thus whether<br />
the two curves are <strong>in</strong> phase.
The warp<strong>in</strong>g function h(t)<br />
Every smooth strictly monotone function<br />
h(t) such that h(0) = 0 can be<br />
represented as<br />
t<br />
ht () C exp wvdvdu ( )<br />
u<br />
= ∫ ∫<br />
0 0<br />
We represent unconstra<strong>in</strong>ed function<br />
w(v) by a B-spl<strong>in</strong>e expansion. Constant<br />
C is determ<strong>in</strong>ed by constra<strong>in</strong>t h(T) = T.
The deformation d(t) = h(t) - t<br />
Plott<strong>in</strong>g this allows us to see when the<br />
seasons come early (negative<br />
deformation) or late (positive<br />
deformation).
• Mid-w<strong>in</strong>ter for 1989-1990 1990 arrived about<br />
25 days early.<br />
• The next step is to register the<br />
temperature data by comput<strong>in</strong>g x*(t) =<br />
x[h(t)]. The registered curve x*(t)<br />
conta<strong>in</strong>s only amplitude variation.<br />
• Registration was done by Matlab<br />
function registerfd, , available by ftp from<br />
ego.psych.mcgill<br />
mcgill.ca/pub/ .ca/pub/ramsay/FDAfuns
<strong>Amplitude</strong> variation<br />
• The st<strong>and</strong>ard deviation of the difference<br />
between the unconstra<strong>in</strong>ed smooth <strong>and</strong><br />
the strictly periodic smooth is 2.15 C.<br />
• The st<strong>and</strong>ard deviation of the difference<br />
between the registered smooth <strong>and</strong> the<br />
periodic smooth is 1.73 C.<br />
• (2.15 2 – 1.73 2 )/2.15 2 = .35, the proportion<br />
of the variation due to phase.
• The st<strong>and</strong>ard deviation of the raw data<br />
around the registered smooth is 2.13 C,<br />
compared with 2.07 C for the<br />
unregistered smooth.<br />
• About 10% of the total variation is due<br />
to phase.
Conclusions<br />
• <strong>Phase</strong> variation is an important part of<br />
weather behavior.<br />
• Statisticians seldom th<strong>in</strong>k about phase<br />
variation, <strong>and</strong> classical time series<br />
methods ignore it completely.<br />
• <strong>Phase</strong> variation needs more attention, <strong>and</strong><br />
registration is an essential tool.