Interactive visualisation and exploration of one dimensional time series, based on pretty_ts.

vis_ts(data)

Arguments

data

A dataframe containing a response variable, time stamps (and, optionally) explanatory variables. Time stamps can be integer/numeric, DateTimeClasses or a Date objects.

Value

An interactive R Shiny application for visualising time series.

Author

Edward Lavender

Examples

if (FALSE) { #### Example (1) Visualising POSIXct time series # Here we have a simple dataframe... other columns (i.e. covariates) can be included # ... alongside factor columns. x <- seq.POSIXt(as.POSIXct("2016-01-01", tz = "UTC"), as.POSIXct("2016-01-10", tz = "UTC"), by = "2 hours") y1 <- rnorm(length(x), 200, 25) *-1 y2 <- rnorm(length(x), lubridate::yday(x) * 0.5 +20, 0.5) dat <- data.frame(x = x, y1 = y1, y2 = y2) #### Launch shiny vis_ts(data = dat) } if (FALSE) { #### Example (2) Visualising numeric time series x <- 1:1000 y <- rnorm(length(x), x*0.1- 500, 1000) y2 <- rnorm(length(x), x*0.5, 500) vis_ts(data = data.frame(x = x, y = y, y2 = y2)) }