串扰使滚动条在flexdashboard中与reactable组合时不可见
我使用卓越的串扰使滚动条在flexdashboard中与reactable组合时不可见,r,flexdashboard,htmlwidgets,crosstalk,R,Flexdashboard,Htmlwidgets,Crosstalk,我使用卓越的串扰r包为我的可反应htmlwidget制作过滤器。我在flexdashboard中显示可反应的。当使用reactible的groupBy功能时,我注意到当我将表格设置为大于其所在区域时,没有滚动条 下面是一个有助于澄清问题的示例: --- title: "Focal Chart (Top)" output: flexdashboard::flex_dashboard: orientation: rows --- Row {data-height=500} -----
串扰r包
为我的可反应htmlwidget制作过滤器。我在flexdashboard
中显示可反应的。当使用reactible
的groupBy
功能时,我注意到当我将表格设置为大于其所在区域时,没有滚动条
下面是一个有助于澄清问题的示例:
---
title: "Focal Chart (Top)"
output:
flexdashboard::flex_dashboard:
orientation: rows
---
Row {data-height=500}
-------------------------------------
### Chart 1
```{r}
library(crosstalk)
library(reactable)
```
Row {data-height=500}
-------------------------------------
### With crosstalk filtering
```{r}
cars <- MASS::Cars93[1:20, c("Manufacturer", "Model", "Type", "Price")]
data <- SharedData$new(cars)
bscols(
widths = c(3, 9),
list(
filter_checkbox("type", "Type", data, ~Type),
filter_slider("price", "Price", data, ~Price, width = "100%"),
filter_select("mfr", "Manufacturer", data, ~Manufacturer)
),
reactable(data,groupBy = "Manufacturer")
)
```
### Without crosstalk
```{r}
reactable(data,groupBy = "Manufacturer")
```
---
标题:“焦点图(顶部)”
输出:
flexdashboard::flex_仪表板:
方向:行
---
行{数据高度=500}
-------------------------------------
###图1
```{r}
图书馆(串扰)
库(可反应)
```
行{数据高度=500}
-------------------------------------
###带串扰滤波
```{r}
汽车我不认为这是一个完整的答案,但它可能会让你更接近。我夸大了最小宽度,这样你就能看到效果
sticky_style <- list(position = "sticky", left = 0, background = "#fff", zIndex = 1,
borderRight = "1px solid #eee")
crosstalk::bscols(
widths = c(3, 9),
list(
filter_checkbox("type", "Type", data, ~Type),
filter_slider("price", "Price", data, ~Price, width = "100%"),
filter_select("mfr", "Manufacturer", data, ~Manufacturer)
),
reactable(data,columns = list(
Manufacturer = colDef(
style = sticky_style,
headerStyle = sticky_style
)
), defaultColDef = colDef(minWidth = 300))
)
sticky\u style我在reactable(data,groupBy=“Manufacturer”)中得到了错误:`data`必须是一个数据框或矩阵
@DanielJachetta,这看起来很奇怪,因为我是从ractable网站复制代码的。在我的系统中,一切似乎都很好。也许你对这个问题也有想法?