dygraphs
dygraphs copied to clipboard
Implement option `visibility` to toggle series visibility on/off
This is just an enhancement/feature request to implement existing JavaScript visibility
option:
From http://dygraphs.com/tests/visibility.html :
new Dygraph(
document.getElementById("div_g"),
NoisyDataABC, {
rollPeriod: 7,
errorBars: true,
visibility: [false, true, true]
}
);
In R dygraphs it doesn't work yet:
library(dygraphs)
lungDeaths <- cbind(ldeaths, mdeaths, fdeaths)
dygraph(lungDeaths, main = "Deaths from Lung Disease (UK)") %>%
dyOptions(visibility=c(TRUE,FALSE, TRUE))
Should be also a per-series option:
dygraph(lungDeaths, main = "Deaths from Lung Disease (UK)") %>%
dySeries(name='mdeaths", visibility=FALSE)
Thank you