STAT443 Assignment # 1 Fall 2019 Instructor: S. Chenouri Due: October 11th, 2019, by 11:59 pm
For any parts involving R, you should hand in the R code and output, as well as your interpretations of the output. You will NOT receive marks for uncommented R code or output. You must submit your assignment through CrowdMark.
Problem 1. [20 mark in total] In an R session load the following time series objects and answer the questions (a) to (e) below.
1. Monthly average CO2: Atmospheric carbon dioxide concentrations in parts per million (ppm) are re- ported on Learn under Datasets in the file “co2 mm mlo.txt” which is obtained from NOAA. “Carbon dioxide is a greenhouse gas: a gas that absorbs heat. Warmed by sunlight, Earth’s land and ocean surfaces continuously radiate thermal infrared energy (heat). Unlike oxygen or nitrogen (which make up most of our atmosphere), greenhouse gases absorb that heat and release it gradually over time, like bricks in a fireplace after the fire goes out. Without this natural greenhouse effect, Earth’s average annual temperature would be below freezing instead of close to 60oF. But increases in greenhouse gases have tipped the Earth’s energy budget out of balance, trapping additional heat and raising Earth’s average temperature.”
Read the data file “co2 mm mlo.txt” into R and study the time series given by the column “interpolated”.
2. Land-Ocean Temperature Index: Global-mean monthly combined Land-Surface Air and Sea-Surface Water Temperature Anomalies (Land-Ocean Temperature Index, LOTI), i.e. deviations from the cor- responding 1951-1980 means are obtained from NASA webpage and are stored in the file “GLB.csv” on Learn under Datasets. It contains seasonal, and annual means, 1880-present, updated through the most recent month.
3. JohnsonJohnson: Quarterly earnings (dollars) per Johnson & Johnson share 1960-1980. Use the com- mand data(JohnsonJohnson) in R to call this dataset.
4. UKgas: Quarterly UK gas consumption from 1960Q1 to 1986Q4, in millions of therms. Use the command data(UKgas) in R to call this dataset.
For each time series comment briefly on the following aspects. Justifying your comments if possible.
(a) What is the period of the time series? [1 mark for each dataset]
(b) Is there a seasonal effect and, if so, is it additive or multiplicative? [1 mark for each dataset]
(c) What can you say about the level and trend? [1 mark for each dataset]
(d) Do you think that there are any change points? [1 mark for each dataset]
(e) Are the time series stationary? [1 mark for each dataset]
You may use the R function decompose( ) for exploring additive and multiplicative forms, wherever applicable.
1
Problem 2. [15 mark in total] Suppose Yt = β0 + β1 t + Zt , where {Zt } is a zero-mean stationary series with auto-covariance γk and β0 and β1 are constants.
(a) [3 mark] Show that {Yt } is not stationary but that Wt = ∇Yt = Yt − Yt−1 is stationary.
(b) [6 mark] Now assume Zt is a white noise process with mean zero and variance σ2. Show that the mean
of the moving average
1 q
Yt−j
is β0 + β1 t, and give a simplified expression for the auto-covariance function.
Vt = 2 q + 1
(c) [6 mark] In general, show that if Yt = μt + Zt , where {Zt } is a zero-mean stationary series and
d
μt =cktk,t=0,±1,…
k=0
is a polynomial in t of degree d, then ∇mY = ∇ ∇m−1Y is stationary for m ≥ d and non-stationary
for 0 ≤ m < d.
Problem 3. [10 mark in total] Which of the following processes is stationary for T = {t : t = 0, 1, 2, . . . }, where Zt are independent and identically distributed random variables with mean 0 and variance 1, and a1 and a2 are fixed real numbers? Show all your steps.
(a) [4 mark] Xt = Z1 + Z2 cos(t) + Z3 sin(t).
(b) [3mark]Xt=a1+at2Z1+Z2for0
Var(Yt−k) , Var(Yt )
Cov(Yt, Yt−1) = Cov(c Yt−1 + Zt, Yt−1) . (d) [3 mark] For large t, argue that
σ2
Var(Yt) ≈ z and Corr(Yt, Yt−k) ≈ ck k > 0,
1−c2
so that {Yt} could be called asymptotically stationary.
2
(e) [6 mark] Suppose now that we alter the initial condition and put Y1 = √ Z1 .
1−c2
Show that now {Yt} is stationary.
Problem 5. [15 mark in total] The data file retail.txt, on Learn under Datasets, lists total U.K. (United Kingdom) retail sales (in billions of pounds) from January 1986 through March 2007. The data are not “seasonally adjusted”, and the year 2000 = 100 is the base year.
(a) [2 mark] Display and interpret the time series plot for these data. Be sure to use plotting symbols that permit you to look for seasonality.
(b) [3 mark] Use least squares to fit a seasonal-means plus linear time trend to this time series. Interpret the regression output and save the standardized residuals from the fit for further analysis.
(c) [2 mark] Construct and interpret the time series plot of the standardized residuals from part (b). Be sure to use proper plotting symbols to check on seasonality.
(d) [2 mark] Obtain the least squares residuals from a seasonal-means plus linear time trend model.
(e) [2 mark] Perform a runs test on the standardized residuals and interpret the results.
(f) [2 mark] Calculate and interpret the sample autocorrelations for the standardized residuals.
(g) [2 mark] Investigate the normality of the standardized residuals (error terms). Consider histograms and normal probability plots. Interpret the plots.
Problem 6. [10 mark in total] Suppose that a stationary time series, {Yt }, has an autocorrelation function oftheformρk =φk fork>0,whereφisaconstantintherange(−1,+1).
n
(a) [6 mark] For the mean Y = n−1 Yt, show that t=1
γ 1+φ 2φ(1−φn) Var(Y)=0 − 2.
(b) [2 mark] If n is large, argue that
n 1−φ n(1−φ)
Var(Y)≈γ0 ·1+φ. n 1−φ
(c) [2 mark] Plot (1 + φ)/(1 − φ) for φ over the range −1 to +1. Interpret the plot in terms of the precision in estimating the process mean.
3