ST422-Rstudio代写
时间:2022-12-05











Time Series Week 8
ST422 Assessed Coursework
Deadline: 9am, December 9, 2022
1 Questions
The three .csv files on the ST422 Moodle page under “Monthly Rainfall,
mean temperature and bright sunshine duration” are the monthly data files
required. Each file contains the corresponding monthly measurements, to-
gether with seasonal and annual aggregations.
1. Read the monthly data into 3 different time series vectors, ignoring the
aggregated level data in the files. Present time series plots to display
the data, and other proper plots that you think is helpful to reveal the
structure of the data. Describe what you found.
2. Using the knowledge you gained from part 1, find time series models to
separately model the 3 different series. Write down the fitted models
for the 3 time series, and produce predicted values for both November
and December 2022 for the 3 series. Remember to briefly justify your
final models chosen.
3. Do the following for each series:
Split the data into 75% (the first 75% of data points) training data and
25% validation data. Use a rolling window to predict the next monthly
measurement for the training data. Write an R function to compute
the monthly squared prediction error, and aggregate them to form a
final prediction error for each window length. Find a window length to
minimise this prediction error.
Repeat the above for the validation data. Does the window length
found for the training data match the one found for the validation
data?
Determine on a window length (with reasons), and predict the mea-
surements for both November and December 2022. Are they close to
the answers in part 2?
4. Research on vector ARMA (VARMA) model, and write down its def-
inition. Find an R package to fit a VARMA model for the 3 series,
November 12, 2022 ST422 1 c©Copyright Clifford Lam 2022
Time Series Week 8
and make a prediction especially for the monthly mean temperature
for November and December 2022. You may use as much data avail-
able to you to make such predictions, or choose a window length to do
so. But in both cases, you need to justify why you do so. You may
consider generalising the procedure in part 3 to a VARMA model.
2 Submission
• Submit your work anonymously under your candidate number in
LSE For You. (NOT your ID Number starting with 20XX)
• Plagiarism will be checked, and students who found to plagiarise will
not only be penalised, but also face potential disciplinary actions from
the school.
• Upload a single pdf file to the corresponding course-work upload link
on Moodle.
• The single pdf file should contain your presented answers including
graphs and tables. All R codes used should be added in an appendix
in the end.
• The upload link will stop working after the deadline indicated on the
link. You can still submit then by sending the file directly to me.
Late submission will result in penalties: 5 marks (out of maximum
100) will be deducted for every half-day (12 hours). This will result in a
maximum penalty of 10 marks for the first 24 hours. A further 5 marks
will be deducted per 24 hour period thereafter (including weekends.)
• Extensions to deadlines for coursework will only be given in fully doc-
umented serious extenuating circumstances.
November 12, 2022 ST422 2 c©Copyright Clifford Lam 2022


essay、essay代写