PlotTimeSeries: PlotTimeSeries

View source: R/PlotTimeSeries.R

PlotTimeSeriesR Documentation

PlotTimeSeries

Description

Plots time series as a ploty object for interactive purposes like zooming or investigating specific points of time with mouse

Usage

PlotTimeSeries(X, Y, xlab = "X", ylab = "Y",

main = "Timeseries by Plotly", col = "black", SaveIt = FALSE)

Arguments

X

[1:n] vector, both lines require the same xvalues, e.g. the time of the time series, POSIXlt or POSIXct are accepted

Y

[1:n] vector of first line

xlab

Optional, string for xlabel. Default is "X"

ylab

Optional, string for ylabel. Default is "Y"

main

Optional, title of plot. Default is "Timeseries by Plotly"

col

Optional, color of two lines. Default is "black"

SaveIt

Optional, TRUE if you want to save plot as html in getwd() directory. Default is FALSE

Details

Enables to visualize the time series interactively, using plotly

Value

plotly object

Note

Wrapper in order to unify Input and Output

Author(s)

Michael Thrun

Examples

data(ElectricityBRD)
PlotTimeSeries(ElectricityBRD$Mrd_KWh, ElectricityBRD$Time, "Mrd KWh", "Time", "Electricity production in BRD")

Mthrun/TSAT documentation built on Feb. 5, 2024, 11:15 p.m.