rbokeh
rbokeh copied to clipboard
tool positioning lost when using grid
The toolbar_location works fine with one figure, however is ignored (and the default is used) with a grid setup. I'll see if can determine how to fix this, in the meantime posting as a bug.
x <- seq(as.POSIXct("2011-1-1 08:00", tz='UTC'), as.POSIXct("2011-1-1 08:30", tz='UTC'), len=400)
y <- 1:400 * 0.1 + rnorm(400, sd=2)
tool.loc <- 'right'
tool.set <- c('pan', 'wheel_zoom')
fig1 <- figure(toolbar_location=tool.loc, tools=tool.set) %>%
ly_lines (x, y)
fig2 <- figure(toolbar_location=tool.loc, tools=tool.set) %>%
ly_lines (x, y)
grid_plot(list(fig1, fig2), nrow=2, ncol=1, same_axes=c(T,F))
If one instead evaluates just fig1, then will render with the toolbar on the right.
I modified the fig_grid.R code experimentally to make use of a toolbar_location parameter. However noted, probably as the author did, that the positioning of the toolbar only works for left and above. Perhaps bokeh does not know the proper dimensions of the grid and thus cannot position to the right or below. Don't know whether this is a bokeh JS limitation or whether is a limitation in terms of how the grid was generated.