Skip to content

Instantly share code, notes, and snippets.

@timelyportfolio
timelyportfolio / code.R
Created December 21, 2014 21:33
htmlwidgets dygraphs only show highlighted legend
library(dygraphs)
lungDeaths <- cbind(ldeaths, mdeaths, fdeaths)
dygraph(lungDeaths, main = "Deaths from Lung Disease (UK)") %>%
dyHighlight(highlightSeriesOpts = list(strokeWidth = 3)) -> d1
#this is a hack to set css directly
# dyCSS designed to read a text css file
d1$x$css = "