Description Usage Arguments Value Examples
View source: R/AddShadedRegion.R
Specify the region of a dyGraph
, this function will add a
background shading of color
at specified region
1 | AddShadedRegion(dyGraph, highlight, color = "red")
|
dyGraph |
A dygraph object to add shading to |
color |
Color of shading. This can be of the form "#AABBCC" or "rgb(255, 100, 200)" or "yellow". Defaults to be red. |
hightlight |
A logical vector - must be of the same length as the time of
|
A dygraph with the specified shading
1 2 3 4 | set.seed(1)
p <- PlotTimeSeries(ProcessorTime, "time", c("BN2", "CO4"))
highlight <- sample(c(T, F), length(ProcessorTime$time), replace = TRUE, prob = c(0.1, 0.9))
AddShadedRegion(p, highlight)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.