Description Usage Arguments Details Value Forecast References Examples

Draws a plot of a given `iNZightTS`

object with the trend superimposed.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | ```
## S3 method for class 'iNZightTS'
plot(
x,
multiplicative = FALSE,
ylab = obj$currVar,
xlab = "Date",
title = "%var",
animate = FALSE,
t = 10,
smoother = TRUE,
aspect = 3,
plot = TRUE,
col = ifelse(forecast > 0, "#0e8c07", "red"),
xlim = c(NA, NA),
model.lim = NULL,
seasonal.trend = FALSE,
forecast = 0,
...
)
``` |

`x` |
an |

`multiplicative` |
logical. If |

`ylab` |
a title for the y axis |

`xlab` |
a title for the x axis |

`title` |
a title for the graph |

`animate` |
logical, if true the graph is animated |

`t` |
smoothing parameter |

`smoother` |
logical, if |

`aspect` |
the aspect ratio of the plot; it will be about ASPECT times wider than it is high |

`plot` |
logical, if |

`col` |
the colour of the smoothed trend line |

`xlim` |
axis limits, specified as dates |

`model.lim` |
limits of the series to use for modelling/forecast |

`seasonal.trend` |
logical, if |

`forecast` |
numeric, how many observations ahead to forecast (default is 0, no forecast) |

`...` |
additional arguments (not used) |

If animate is set to `TRUE`

, a scatterplot of all points in the
time series will appear followed by slowly drawn lines connecting the
points, simulating the drawing of a time series by hand.

a time series plot (constructed with ggplot2) is returned invisibly, which can be added to if desired.

The predictions and prediction intervals are the result of models fitted by the Holt-Winters method. The amount of predicted observations is specified by the value of 'forecast'.

C.C Holt (1957) Forecasting seasonals and trends by exponentially weighted moving averages, ONR Research Memorandum, Carnegie Institute 52.

P.R Winters (1960)
Forecasting sales by exponentially weighted moving averages,
*Management Science* **6**, 324–342.

1 2 3 4 5 |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.