小编Jor*_*rdi的帖子

闪亮 - 使用insertUI的动态数据过滤器

我是新手,并且正在尝试编写一个用户可以动态添加数据过滤器的应用程序(请参阅下面的代码).我认为insertUI和删除UI非常酷.但是,我有几个问题:

    1) I cannot address dynamically generates input$ids (see filterId in the code, l. 36 and l. 58)
    2) in updateCheckboxGroupInput (l. 62) checkboxes are not preselected.
    3) I cannot select data rows using which() (l. 74)
    4) The checkboxes are not displayed inside the column, but spread over the whole page.
Run Code Online (Sandbox Code Playgroud)

我非常感谢任何提示.

谢谢,Jordi

这里的代码:

library(shiny)

rowvalues <- function(col,data) {
  as.list(unique(data[col]))
}

ui <- fluidPage(
  sidebarLayout(
    sidebarPanel(
      fluidRow(
        column(6, actionButton('addFilter', 'Add filter')),
        column(6, actionButton('removeFilter', 'Remove filter')),
        offset = 6
      ), …
Run Code Online (Sandbox Code Playgroud)

r filter shiny

3
推荐指数
1
解决办法
1487
查看次数

标签 统计

filter ×1

r ×1

shiny ×1