status R build
status Downloads


The R package fpp2 loads data required for the examples and exercises used in the book Forecasting: Principles and Practice (2nd edition) by Rob J Hyndman and George Athanasopoulos. It also loads several packages needed to do the analysis described in the book.


You can install the stable version from CRAN.

install.packages('fpp2', dependencies = TRUE)

You can install the development version from Github

# install.packages("remotes")


library(fpp2) will load the following packages:

You also get a condensed summary of conflicts with other packages you have loaded:

#> Registered S3 method overwritten by 'quantmod':
#>   method            from
#> zoo
#> ── Attaching packages ──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────── fpp2 2.4 ──
#> ✓ ggplot2   3.3.2           ✓ fma       2.4        
#> ✓ forecast     ✓ expsmooth 2.4

Try the fpp2 package in your browser

Any scripts or data that you put into this service are public.

fpp2 documentation built on Sept. 13, 2020, 5:17 p.m.