library(forecast)
library(ggplot2)
<- cbind(mdeaths, fdeaths)
lungDeaths autoplot(lungDeaths, facets=TRUE)

9 September 2016
I’ve pushed a minor update to the forecast package to CRAN. Some highlights are listed here.
You can now facet a time series plot like this:
library(forecast)
library(ggplot2)
lungDeaths <- cbind(mdeaths, fdeaths)
autoplot(lungDeaths, facets=TRUE)
So autoplot.mts
now behaves similarly to plot.mts
The fitted
function has a new argument h
to allow computation of in-sample fitted values of more than one-step-ahead. In time series, fitted values are defined as the one-step-forecasts of the data used in training a model. Sometimes it is useful to have corresponding (h)-step forecasts, where (h>1). This is now possible.
The Theta method was proposed by Assimakopoulos and Nikolopoulos (2000), and has been repeatedly shown to produce remarkably good forecasts. I included a non-seasonal form of the method (via thetaf
) in the forecast package a long time ago, but I’ve now updated it to allow for seasonal time series as well. It is not quite identical to the A&N method, due to differences in optimization criteria, but it is close.
With the forecast package being increasingly used for large scale automatic forecasting, it is important that it does not fail on edge cases such as time series consisting of 2 or 3 observations. I’ve made some new tweaks to allow ets()
and auto.arima()
to produce sensible results in these cases. I wouldn’t bet my house on forecasts using only 2 observations, but they aren’t too bad.
The package has long offered seasonal adjustment via the seasadj
function, applied to objects created using stl
, decompose
, and tbats
. This has now been generalized to an S3 function so other people can write S3 seasonal adjustment methods.
The various modelling functions have either used x
as the first argument or y
as the first argument, to refer to the univariate time series to be modelled. To be consistent, this is now y
in all functions. However, x
will still work to avoid backwards compatibility issues.
As usual, there have been lots of bug fixes, mostly in functionality introduced in v7. More details are provided in the Changelog or in the github commits.