0

I am making multiple dygraphs in a R markdown document. Each dygraph should be in it's own tabset. The code for one of my dygraphs is the following:

# Make a dygraph
dygraph(xts_data, main = "Totaal van nieuwe tickets") %>%
  dyRangeSelector() %>%
  dyHighlight(highlightCircleSize = 5, 
          highlightSeriesBackgroundAlpha = 0.2,
          hideOnMouseOut = TRUE) %>%
  dyLegend(width = 600) %>%
  dyOptions(colors = RColorBrewer::brewer.pal(4, "Dark2")[c(1,3,4)],
        fillGraph = TRUE, fillAlpha = 0.4)

This code is properly put within a tabset which is created through the following code:

## Ticket data {.tabset .tabset-fade .tabset-pills}

Now what seems to have is that each time I open a new tab, it doesn't properly display the dygraph. Only when I resize the compiled html document, the graph becomes properly visible again. Has anyone had a similar experience and knows how to solve this?

Bobby en Bezemer
  • 103
  • 1
  • 1
  • 4
  • Looks like this got fixed here https://github.com/rstudio/dygraphs/commit/6ed9f961c7cafd414ae4b7c994f6e3b652d4884b and in news for `0.7` https://cran.r-project.org/web/packages/dygraphs/NEWS. Have you tried the newest `dygraphs`? – timelyportfolio May 02 '16 at 02:13
  • Thanks, I downloaded the new dygraph package and now it seems to work perfectly ! – Bobby en Bezemer May 02 '16 at 08:28

0 Answers0