代写AEM 4110/5111 – Introduction to Econometrics Problem Set 6代做Python编程

Problem Set 6

AEM 4110/5111 – Introduction to Econometrics

Fall 2025

Note: Part II (seasonality) is optional

Instructions

This problem set is due by 12/10 at 11:59pm.

•  Submit your answers via Canvas in the assignments section of the course.

•  Submit a zipped folder with the following documents.  The zipped folder should be named according to “PS6” “lastname”

1. A write-up in PDF format with your answers to the questions below and the full names of all your group members.

2. A do-file with the Stata code you use for your answers.  In the do-file,  comment your script specifying which sections correspond to each answer in your write-up.

3. For the questions that require filling a table, you can create one in Excel or using LaTeX.

4. Important! Please write each answer on a separate page and clearly label it with the corresponding question number (for example, Question I.1.a, Question I.1.b, etc.).

Set Up

The Goal In this problem set, you will apply time series methods to analyze U.S. Consumer Price Index (CPI) data.  Specifically, you will work with month-over-month CPI growth rates from January 1980 to March 2024.   The dataset has been deseasonalized  to focus on the core autoregressive and moving average structure; you will examine the original seasonal patterns in Part 2.

Data: The file cpi data.dta contains the following variables:

•  cpi deseason: Deseasonalized month-over-month CPI growth rate (in percentage points)

•  cpi raw: Original (non-deseasonalized) month-over-month CPI growth rate

date: Date variable (monthly, from 1980m1 to 2024m3)

t: Time index (1, 2, 3, ..., 531)

The cpi raw series comes from the Federal Reserve Bank of St. Louis website FRED.

Part I: Model Selection

In this part, you will work exclusively with the deseasonalized CPI growth series (cpi deseason).

1 Let’s start with some data exploration

a) Load the dataset and declare it as time series data using the tsset command.

b)  Create a time series plot of cpi deseason using the tsline command.  Include this graph in your submission.

c)  Briefly describe the visual properties of the series.   Does  it appear to fluctuate around a constant mean? Are there any obvious trends or structural breaks?

2 Next, we want to make sure that the series is stationary.

a)  Conduct an Augmented Dickey-Fuller (ADF) test for cpi deseason using the dfuller com- mand as we saw in class.

b)  Report the test statistic, and the 1%, 5%, and 10% critical values.

c)  State the null and alternative hypotheses for the ADF test.  Based on your results, do you reject or fail to reject the null hypothesis at the 5% significance level?

d) Interpret your conclusion in plain language: is the series stationary or non-stationary? Why do we want a stationary series?

3 Let’s now use the ACF and PACF to help us guide the choice of the model.

a)  Generate and display the autocorrelation function (ACF) for the first 24 lags using the ac command. Include the graph in your submission.

b) Examine the ACF plot. Which lags have autocorrelations that are statistically significant (i.e., outside the confidence bands)? Describe the overall pattern (e.g., does it decay gradually or cut off sharply?).

c)  Generate and display the partial autocorrelation function (PACF) for the first 24 lags using the pac command. Include the graph in your submission.

d) Examine the PACF plot.   Which lags have partial autocorrelations that are statistically significant? Describe the pattern.

4 We are now going to use the command arima to estimate different ARMA models, and use the Information Criteria to help us select the model among them that best fits the data.

Estimate the following six ARMA specifications for cpi deseason:

i) AR(1): arima  cpi deseason,  ar(1)

ii) AR(2): arima  cpi deseason,  ar(1/2)

iii)  MA(1): arima  cpi deseason, ma(1)

iv)  MA(2): arima  cpi deseason, ma(1/2)

v) ARMA(1,1): arima  cpi deseason,  ar(1) ma(1)

vi) ARMA(2,2): arima  cpi deseason,  ar(1/2) ma(1/2)

For each model:

a)  Report the estimated coefficients for the AR and MA terms, along with their standard errors and p-values in a table for each model.

b)  Briefly comment on the signs of the significant coefficients.  Do they align with the patterns you observed in the ACF and PACF?

c) After each regression, use the estat  ic post-estimation  command to obtain the Akaike In- formation Criterion (AIC) and Bayesian Information Criterion (BIC) for each model.

d) After compiling the table for all 6 models:  Which model is selected as best” according to AIC? Which model is selected as “best” according to BIC? Do the two criteria agree?

Note:

•  Run estat  ic immediately after each arima estimation to capture the AIC and BIC values before proceeding to the next model.

• For part c),  compile the  AIC  and BIC values for all six models into one comprehensive comparison table to facilitate model selection.

5 In class we discussed that the residual of a “good model” should not contain any information that helps us predict future values of the series.  In other words, we want our residuals to be “White Noise”.  Let’s verify that this is the case for the model you selected in Question 4 (use the BIC criterion if AIC and BIC disagree). For this model:

a) After estimation, predict the residuals using predict  resid,  residuals.

b)  Plot the residuals to see their distribution. Use the command histogram  resid,  bins(40). Do the residuals appear approximately normally distributed?  Is the distribution centered around 0?

c) [For AEM 5111 only] Generate the ACF and PACF of the residuals for the first 20 lags using ac  resid,  lags(20). Include the graph in your submission.

d) [For AEM 5111 only] Based on the ACF and PACF of the residuals, do you think that the residuals are ~ i.i.d. N(0,σ2 )?  Why/why not?  What does this suggest about model adequacy?

Optional Part II: Seasonality

In Part I, you worked with deseasonalized data to focus on the core ARMA structure.  In this part, you will examine the original, non-deseasonalized CPI growth series (cpi raw) to understand why deseasonalization was necessary and how it can be performed.

1 Let’s start with some visual exploration of the series cpi raw.

a)  Create a time series plot of  cpi raw using tsline.   Compare this visually to the plot of cpi deseason from Question 1 in Part I. Do you notice any recurring patterns or cycles in the raw series?

b)  Generate the ACF for cpi raw with 24 lags. Include the graph in your submission.

c)  Generate the PACF for cpi raw with 24 lags. Include the graph in your submission.

d) Looking at the ACF for cpi raw, at which lag(s) do you see particularly large spikes that were not present (or much smaller) in the deseasonalized data? What does this tell you about the seasonality of the data?

2    [AEM  5111  only] Let’s now see how we can deseasonalize the data.  The most simple way to remove seasonality is to include month-of-year dummy variables in a regression and retain the residuals.   This method explicitly estimates and removes the average  “effect”  of each calendar month.  The residuals contain the variation in the series which is not explained by the monthly patterns.

a) First, create a month variable:

gen month =  month(dofm(date))

This extracts the month (1=January, 2=February, . . . , 12=December) from the date.

b)  Run the following regression:

reg cpi_raw i . month

This is equivalent to regressing cpi raw on 11 dummy variables and a constant.

c)  Explain what each  coefficient  in this regression represents.   For  example,  what  does  the coefficient on 2 .month (February) tell you?

d)  Generate the residuals from this regression:

predict cpi_des , residuals

These residuals represent the deseasonalized series: they are what remains of cpi raw after removing the average effect of each month.

e)  Plot the ACF and PACF of the cpi des variable. What do you notice?  How does it compare to the graphs you obtained from the raw series?

Optional Questions

a) Why would it be a problem to estimate the ARMA model on the raw series, i.e., without accounting for seasonality?

b) In the previous question, we removed the predictable effect of each month on the cpi raw variable. Imagine instead that you are interested in removing the effect of each quarter of the year. How would you do it? Please describe how you would modify the above procedure.

Notes on Deasonalization Method The series cpi deseasonalized was obtained using a dif- ferent deseasonalization procedure called “ X-13ARIMA-SEATS”. This is a method developed by the U.S. Census Bureau and used by professionals. You can read more about it here.

Using dummies to deseasonalize the series is very simple, but a drawback is that it imposes that the effect of each month is constant over the years.



热门主题

课程名

mktg2509 csci 2600 38170 lng302 csse3010 phas3226 77938 arch1162 engn4536/engn6536 acx5903 comp151101 phl245 cse12 comp9312 stat3016/6016 phas0038 comp2140 6qqmb312 xjco3011 rest0005 ematm0051 5qqmn219 lubs5062m eee8155 cege0100 eap033 artd1109 mat246 etc3430 ecmm462 mis102 inft6800 ddes9903 comp6521 comp9517 comp3331/9331 comp4337 comp6008 comp9414 bu.231.790.81 man00150m csb352h math1041 eengm4100 isys1002 08 6057cem mktg3504 mthm036 mtrx1701 mth3241 eeee3086 cmp-7038b cmp-7000a ints4010 econ2151 infs5710 fins5516 fin3309 fins5510 gsoe9340 math2007 math2036 soee5010 mark3088 infs3605 elec9714 comp2271 ma214 comp2211 infs3604 600426 sit254 acct3091 bbt405 msin0116 com107/com113 mark5826 sit120 comp9021 eco2101 eeen40700 cs253 ece3114 ecmm447 chns3000 math377 itd102 comp9444 comp(2041|9044) econ0060 econ7230 mgt001371 ecs-323 cs6250 mgdi60012 mdia2012 comm221001 comm5000 ma1008 engl642 econ241 com333 math367 mis201 nbs-7041x meek16104 econ2003 comm1190 mbas902 comp-1027 dpst1091 comp7315 eppd1033 m06 ee3025 msci231 bb113/bbs1063 fc709 comp3425 comp9417 econ42915 cb9101 math1102e chme0017 fc307 mkt60104 5522usst litr1-uc6201.200 ee1102 cosc2803 math39512 omp9727 int2067/int5051 bsb151 mgt253 fc021 babs2202 mis2002s phya21 18-213 cege0012 mdia1002 math38032 mech5125 07 cisc102 mgx3110 cs240 11175 fin3020s eco3420 ictten622 comp9727 cpt111 de114102d mgm320h5s bafi1019 math21112 efim20036 mn-3503 fins5568 110.807 bcpm000028 info6030 bma0092 bcpm0054 math20212 ce335 cs365 cenv6141 ftec5580 math2010 ec3450 comm1170 ecmt1010 csci-ua.0480-003 econ12-200 ib3960 ectb60h3f cs247—assignment tk3163 ics3u ib3j80 comp20008 comp9334 eppd1063 acct2343 cct109 isys1055/3412 math350-real math2014 eec180 stat141b econ2101 msinm014/msing014/msing014b fit2004 comp643 bu1002 cm2030
联系我们
EMail: 99515681@qq.com
QQ: 99515681
留学生作业帮-留学生的知心伴侣!
工作时间:08:00-21:00
python代写
微信客服:codinghelp
站长地图