STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7)
Outline 1 Midterm Exam Solutions 2 Final Project 3 From Last Time 4 Multiple Series and Cross-Spectra 5 Linear Filters Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 2/ 23
Outline 1 Midterm Exam Solutions 2 Final Project 3 From Last Time 4 Multiple Series and Cross-Spectra 5 Linear Filters Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 3/ 23
Outline 1 Midterm Exam Solutions 2 Final Project 3 From Last Time 4 Multiple Series and Cross-Spectra 5 Linear Filters Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 4/ 23
Homework 4 Homework 4 is due Wednesday, October 24 in class. Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 5/ 23
Final Project Description From the syllabus: Final Project The final project will be a topic of your choice. I will happily suggest a topic should you wish. You will be required to submit a typed report as well as give a 12 minute presentation during the class. The written portion should describe the project, introduce the statistical methodology, present results, and provide discussions. The presentation should be a vibrant powerpoint-type presentation with at most a few words on each slide. Everyone should meet with me at least once before the presentation. Quality is more important than quantity! Two Possibilities: Analyze a dataset from your own research using several techniques from time series analysis Introduce a new topic and, if feasible, use simulated or real data to motivate the new techniques Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 6/ 23
Outline 1 Midterm Exam Solutions 2 Final Project 3 From Last Time 4 Multiple Series and Cross-Spectra 5 Linear Filters Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 7/ 23
Nonparametric Spectral Density Estimation Reduce the influence of γ(h) at extreme values of h. Consider the following estimator: f (ω) = n 1 h= (n 1) λ(h) γ(h)e 2πiω jh where λ(h) starts out at 1 when h 0, but then decreases as h increases. Under general assumptions (for instance ARMA models), using a flat-top lag-window function can guarantee: ) ) ( ) 1 bias ( f (ω) = E ( f (ω) f (ω j ) = O n ) ( ) log n var ( f (ω) = O n ) ( ) log n MSE ( f (ω) = O n Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 8/ 23
Examples of Lag Windows Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 9/ 23
Outline 1 Midterm Exam Solutions 2 Final Project 3 From Last Time 4 Multiple Series and Cross-Spectra 5 Linear Filters Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 10/ 23
Cross Spectrum Recall the cross-covariance function γ xy (h) for a jointly stationary series x t and y t as defined by γ xy (h) = E [(x t+h µ x )(y t µ y )] Taking the Fourier transform, we have the cross-spectrum f xy (ω) = = h= h= γ xy (h)e 2πiωh γ xy (h) cos(2πωh) i } {{ } c xy(ω) h= γ xy (h) sin(2πωh) }{{} qxy(ω) Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 11/ 23
Squared Coherence Function The squared coherence function measures the the strength of the relationship between x t and y t in the frequency domain. Definition (Squared Coherence Function) The squared coherence function is defined as ρ 2 yx(ω) = f yx(ω) 2 f x (ω)f y (ω) Note the analogy to the conventional square correlation given by ρ 2 yx = σ2 yx σ 2 xσ 2 y Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 12/ 23
Spectral Matrix For a p-dimensional stationary vector time series with autocovariance matrix given by Γ(h) = E [ (x t+h µ)(x t µ) ] The spectral matrix is the term-by-term Fourier transform of the autocovariance matrix which can be simply written as f (ω) = h= Γ(h)e 2πiωh, 1/2 ω 1/2 Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 13/ 23
Testing for Significant Coherence Under the hypothesis ρ 2 yx(ω) = 0 the statistic ρ 2 yx(ω) 1 ρ 2 yx(ω) follows an F distribution which allows one to test for significance against the null. Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 14/ 23
Coherence Function Between SOI and Recruitment Series > x = ts(cbind(soi,rec)) > s = spec.pgram(x, kernel("daniell",9), taper=0) > s$df # df = 35.8625 [1] 35.8625 > f = qf(.999, 2, s$df-2) # f = 8.529792 > c = f/(18+f) # c = 0.3188779 > plot(s, plot.type = "coh", ci.lty = 2) > abline(h = c, lwd=3, col="purple") Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 15/ 23
Outline 1 Midterm Exam Solutions 2 Final Project 3 From Last Time 4 Multiple Series and Cross-Spectra 5 Linear Filters Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 16/ 23
Linear Filter Definition A linear filter is a linear transformation of a process x t given as y t = a r x t r r= The coefficients a r are collectively called the impulse response function and it is assumed that they are absolutely summable, i.e. t= a t < Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 17/ 23
Output Spectrum of Filtered Series The impulse response function, A yx (ω), is defined as Fourier transform of the impulse response function, i.e. A yx (ω) = t= a t e 2πiωt Theorem The spectrum of the filtered output y t satsifies f y (ω) = A yx 2 f x (ω) Note the relation to classical statistics where multiplying a random variable X by a constant c changes its variance to c 2 var(x). Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 18/ 23
Two Filters of SOI Let x t represent the SOI values. Consider the two filters: The difference filter y t = x t = x t x t 1 Here a 0 = 1 and a 1 = 1. This is an example of a high-pass filter. The symmetric moving average filter y t = 1 24 (x t 6 + x t+6 ) + 1 12 5 r= 5 x t r Here a 6 = a 6 = 1/24, a k = 1/12 for 5 k 5, and a k = 0 otherwise. This is an example of a low-pass filter. Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 19/ 23
Two Filters Applied to SOI Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 20/ 23
Frequency Response Functions of the Two Examples Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 21/ 23
> w = seq(0,.5, length=1000) #-- frequency response > FR = abs(1-exp(2i*pi*w))^2 > FR2<-double(length(w)) > count<-1 > for(j in w){ + FR2[count]=abs(1/12*(1+cos(12*pi*j)+2*sum(cos(2*pi*j*1:5))))^2 + count<-count+1 + } > plot(w,fr2,type="l",lwd=3,col="blue") > windows() > plot(w, FR, type="l",lwd=3,col="orange") Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 22/ 23
Frequency Response Functions of the Two Examples Here we can see why differencing is referred to as a high-pass filter and the moving average as a low-pass filter. Arthur Berg STA 6857 Cross Spectra & Linear Filters ( 4.6 & 4.7) 23/ 23