TERM 1 2022-r代写
时间:2023-04-28
THE UNIVERSITY OF NEW SOUTH WALES
SCHOOL OF ECONOMICS
TERM 1 2022
ECON2209 BUSINESS FORECASTING
FINAL EXAMINATION
1. Time Allowed: 24 Hours.
2. This is a Take-Home Exam. Your responses must be your own original work.
You must attempt this exam by yourself, without any help from others. By
submitting this exam you are declaring that you have NOT worked, collaborated,
or colluded with any other persons in the formulation of your responses. The
work that you are submitting is your OWN work.
3. Release date/time (via Moodle):
Friday, 29 April 2022, 9:00am (Australian Eastern Standard Time)
4. Submission date/time (Via Turnitin):
Saturday, 30 April 2022, 9:00am (Australian Eastern Standard Time)
5. Submission details:
• A submission link is on the Moodle site under Final Exam.
• Submit your answer document in PDF format. Your file name should
follow this naming convention:
FE_your first name_zID_your last name_ECON2209.pdf
For example: FE_John_z1234567_Smith_ECON2209.pdf
• You get one opportunity to submit your file. Make sure that you submit
the file that you intend to submit.
• Your submitted answers should include the R code that you used.
6. Failure to upload the exam by the submission time will result in an immediate
late penalty of 5% from 9:01am on 30 April, followed by additional penalties of
5% per day or part thereof from the due date and time.
7. This Examination Paper has 6 pages: 2 cover pages and 4 pages with questions.
8. This Examination Paper has 2 parts.
PAGE 2 OF 2
9. Answer all three questions in Part A, and answer ONE of two questions in Part
B. If you answer both questions in Part B, only the first answered question will
be marked.
10. Total marks available: 55 marks. This examination is worth 55% of the total
marks for the course.
11. Questions are not of equal value. Marks available for question sub-parts are
shown on this exam paper.
12. This Take-Home Exam paper cannot be copied, forwarded or shared.
13. Students are reminded of UNSW’s rules regarding Academic Integrity and
Plagiarism. Plagiarism is a serious breach of ethics at UNSW and is not taken
lightly. For details see Examples of plagiarism.
14. This Take-Home Exam is an open book/open web exam. Further information is
available by clicking here.
• You are permitted to refer to your course notes, any materials provided by
the lecturer, books, journal articles, or tutorial materials.
• You are required to cite your sources and attribute direct quotes
appropriately when using external sources (other than your course
materials).
• It is sufficient to use in-text citations that include the following information:
the name of the author or authors; the year of publication; the page number
(where the information/idea can be located on a particular page when
directly quoted), For example, (McConville, 2011, p.188).
• When citing Internet sources, please use the following format: website/page
title and date.
• If you provide in-text citations, you MUST provide a Reference List.
15. Students are advised to read the exam paper thoroughly before commencing.
16. The Lecturer will be available online (via Moodle) after the exam paper is
released for a period of two hours.
UNSW ECON2209 Assessment
Final Exam
2022
• A submission link is on the Moodle site under Final Exam.
• Submit your answer document in PDF format. Your file name should follow this naming convention:
FE_your first name_zID_your last name_ECON2209.pdf
For example: FE_John_z1234567_Smith_ECON2209.pdf
• You get one opportunity to submit your file. Make sure that you submit the file that you intend to
submit.
• Your submitted answers should include the R code that you used.
Remember to type ‘library(fpp3)‘ in the R Studio Console before you start.
Part A: Answer all three questions
Question 1 [20 marks]
This question uses data from the Australian Bureau of Statistics (ABS) on the Australian labour force,
from ABS Catalogue 6202.0, Labour Force: https://www.abs.gov.au/statistics/labour/employment-and-
unemployment/labour-force-australia/latest-release
If you haven’t done so already, install the package readabs:
install.packages("readabs")
Read in data from an Excel spreadsheet on the ABS website using the package and create a
tsibble
library(readabs)
lfs_1 <- read_abs("6202.0", tables = 1) %>%
filter(series_type=="Original") %>%
mutate (Month = yearmonth(date)) %>%
as_tsibble (
index = Month,
key = c (series_id)
)
You must use the following method for selecting your data series.
Use the seven digits of your UNSW student ID to get the data series that you will analyse in this
question, as in the following example for the case when your student ID is Z1234567:
Select your series by replacing “1234567” with the numbers of your student ID:
1
set.seed(1234567)
myseries <- lfs_1 %>%
filter (`series_id` == sample (lfs_1$`series_id` , 1), year(Month)>=2000)
a. [5 marks] Explore your data series using the following functions, being sure to discuss what
you find:
gg_season(), gg_subseries(), gg_lag(), ACF() %>% autoplot()
What Box-Cox transformation, if any, would you select for your data?
b. [5 marks] For your untransformed data series, create a training dataset (myseries_train)
consisting of observations before 2015. Calculate seasonal naïve forecasts using SNAIVE()
applied to your training data and check the residuals. Produce forecasts for the test data.
Compare the accuracy of your forecasts against the actual values.
c. [5 marks] For your full, untransformed data series, apply Holt-Winters’ multiplicative
method to the data. Then try the method making the trend damped. Plot and compare the
12-period ahead point forecasts and prediction intervals for both methods. Using accuracy(),
compare the RMSE of the of the two methods; this comparison is based on one-step-ahead
in-sample forecasts. Which method do you prefer and why?
d. [5 marks] Using the untransformed data, train the models from part c above to the end of
2014 and find the test set RMSE for each. Compare the RMSE values with those from (i) a
seasonal naïve model (ii) a drift model, and (iii) using any transformation previously found
appropriate in part a, an STL-ARIMA model. Discuss.
Question 2 [10 marks]
For your Gross Value Added (GVA) time series from the Course Project:
Develop an appropriate dynamic regression model with Fourier terms for the seasonality. Use
the AICc to select the number of Fourier terms to include in the model. (Use any appropriate
Box-Cox transformation you identified in the Course Project.) Describe your model, and check if
the residual series is white noise.
Hint: For each K, try including e.g. pdq(0:2, 0, 0:2) + PDQ(0:1, 0, 0:1) in your model specification to
help with quickly considering a lot of different models.
5 marks for fitting a sensible model, 5 marks for a sensible description and discussion.
Question 3 [15 marks]
a. [5 mark] Plot the daily closing prices for Amazon stock, using the data contained in
gafa_stock provided by the package fpp3. Also plot the ACF and PACF. Explain how
each of the three plots show that the series is non-stationary and should be differenced.
b. [3 marks] Formally test for stationarity of the Amazon stock series and discuss the results.
How many and what type of differences do you recommend. Why?
c. [2 marks] Figure 1 below shows the ACFs for 36 random numbers, 360 random numbers
and 1,000 random numbers. Explain the differences among these figures. Do they all indicate
that the data are white noise?
d. [5 marks] Why are the critical values at different distances from the mean of zero? Why
are the autocorrelations different in magnitude in each figure when they each refer to white
noise?
2
−1.0
−0.5
0.0
0.5
1.0
5 10 15 20
lag
a
cf
−1.0
−0.5
0.0
0.5
1.0
5 10 15 20
lag
a
cf
−1.0
−0.5
0.0
0.5
1.0
5 10 15 20
lag
a
cf
Figure 1: Left: ACF for a white noise series of 36 numbers. Middle: ACF for a white noise series of 360
numbers. Right: ACF for a white noise series of 1,000 numbers.
Part B: Answer ONLY ONE of the following questions
Question 4 [10 marks]
Consider aus_airpassengers provided by the package fpp3, the total number of passengers (in
millions) from Australian air carriers for the period 1970-2011.
a. [2 marks] Use ARIMA() to find an appropriate ARIMA model. What model was selected.
Check that the residuals look like white noise. Plot forecasts for the next 10 periods.
b. [2 marks] Write the model in terms of the backshift operator.
c. [2 marks] Plot forecasts from an ARIMA(0,1,0) model with drift and compare these to the
forecasts from part a.
d. [2 marks] Plot forecasts from an ARIMA(2,1,2) model with drift and compare these to the
forecasts from parts a and c.
e. [2 marks] Plot forecasts from an ARIMA(0,2,1) model with a constant. What happens?
Explain.
Question 5 [10 marks]
For this question, use the aus_accommodation tsibble as provided by the package fpp3. This has
the total quarterly takings from accommodation and the room occupancy level for hotels, motels,
and guest houses in Australia, between January 1998 and June 2016, along with Consumer Price
Index (CPI) data for each period. Total quarterly takings are in millions of Australian dollars.
a. [2 marks] Compute the CPI-adjusted takings for each state and territory and plot the
resulting series in one figure. Discuss the figure.
b. [3 marks] For Tasmania:
(i) Fit a dynamic regression model of CPI-adjusted takings with a linear trend, seasonal
dummy variables and ARIMA errors.
(ii) Have the seasonal dummy variables adequately handled the seasonality?
3
(iii) Check if the errors are white noise.
c. [3 marks] Forecast the adjusted takings for Tasmania to the end of 2017 and discuss. To do
this. you will need to produce forecasts of the CPI first. For forecasting the CPI, use the
ARIMA model automatically chosen by R.
d. [2 marks] What sources of uncertainty have not been taken into account in the prediction
intervals?
essay、essay代写