R TimeSeries

From ECLR
Revision as of 20:54, 11 February 2015 by Rb (talk | contribs)
Jump to: navigation, search

In this section we will demonstrate how to do basic univariate time-series modelling with R. We will use a package written by Rob Hyndman, called "forecast". So before you get started you need to go to R and

   install.packages("forecast")

But note that this package requires R of version 3. Then at the beginning of your code you will have to import the library by adding

   library(forecast)

to your code. Here we will use a dataset on UK CPI.

Importing Data

Additional Resources

  • A very quick intro from Quick-R can be found here [1]
  • We are using the package "forecast" authored by Rob Hyndman who has also written an online textbook on the topic of forecasting [2]
  • To access some very useful data-series in a very convenient way we will also use the QUANDL package.