littleforecast <- function(data, nyears=10){
fit <- forecast::auto.arima(data)
fc <- forecast::forecast(fit, h = nyears)
ggplot2::autoplot(fc)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.