
year <- sub("-.*", "", meta$Date)
if(!length(year))
  year <- substr(Sys.Date(),1,4)
vers <- meta$Version
if(is.null(vers))
  vers <- packageVersion("forecast")
vers <- paste("R package version", vers)

citHeader("To cite the forecast package in publications, please use:")

bibentry(bibtype = "Manual",
  title = "{forecast}: Forecasting functions for time series and linear models",
  author = as.person("Rob J Hyndman"),
  year = year,
  note = vers,
  url = "http://pkg.robjhyndman.com/forecast")

bibentry(bibtype = "Article",
  title     = "Automatic time series forecasting: the forecast package for {R}",
  author    = personList(as.person("Rob J Hyndman"),as.person("Yeasmin Khandakar")),
  journal   = "Journal of Statistical Software",
  volume    =  26,
  number    =  3,
  pages     = "1--22",
  year      =  2008,
  url       = "http://www.jstatsoft.org/article/view/v027i03")
