Wieder zurück. An einem Projekt arbeiten und ich stecke fest. Mein Klick funktioniert nicht. Ich habe jede Iteration ausprobiert und kann es nicht herausfinden. Grundsätzlich möchte ich mehrere Zeilen in einer Datentabelle durch einen Klick auswählen, an dem ich noch mehr filtern werde. Der Klick, mit dem ich Probleme habe. Hier ist mein Code ... Siehst du etwas, das ich vermisse? Vielen Dank. Bibliothek (Vorhersage) Bibliothek (glänzend) Bibliothek (shinythemes) Bibliothek (ggplot2) Bibliothek (dplyr) Bibliothek (Skalen) Bibliothek (DT)Shiny Datatable Klick ID funktioniert nicht
Bibliothek (Vorhersage) Bibliothek (glänzend) Bibliothek (shinythemes) Bibliothek (ggplot2) Bibliothek (dplyr) Bibliothek (Skalen) Bibliothek (DT)
source("NEW.R", local = TRUE)
branch1 <- unique(distinctlineitems$BRANCH)
ui <- navbarPage(
theme = shinytheme("cosmo"),
title = "EXPENDITURES",
tabPanel("TAB1",
sidebarLayout(
sidebarPanel(
checkboxGroupInput("branches",label = NULL,choices = branch1 ,selected = NULL),
actionButton('selectallB','Select All'),
textInput("words", "Search"),
h5("Separate keywords with commas."),
plotOutput("plot", width = "100%"),
plotOutput("season", width = "100%")),
# Show a plot of the generated distribution
mainPanel(
fluidRow(csvDownloadUI("dwnld", "DOWNLOAD"), style = "padding:10px"),
DT::dataTableOutput("table")
server <- function(input, output, session) {
branchfilter <- reactive({
filt <- distinctlineitems[distinctlineitems$BRANCH %in% input$branches,]
return(filt)
})
graphids <- reactive({
if(length(input$table_rows_selected) < 1) return(NULL)
id <- input$table_rows_selected
x <- branchfilter()$REMARKS[id]
})
output$table <- renderDataTable({
test <- DT::datatable(branchfilter(),
filter = "top",
rownames = FALSE,
selection = "multiple")
})
Was ist dein 'ui'? –
Und noch wichtiger, wo ist 'wordreact()' definiert? –
Würdest du das für mich schließen? Vielen Dank. – astronomerforfun