How to set choices of inputs within server function in shiny app?

0 votes
How to set choices of inputs within server function in shiny app?
Aug 29 in Data Analytics by kajal
19 views

1 answer to this question.

0 votes

@Kajal,

Use renderUI function to add input elements from server functions. For example -

Ex:

#ui function
tabPanel(
      title = "Team wise Stats",
        uiOutput("team_"),
        submitButton("Go"))

#server function 
server <- function(input,output) {
output$team_ = renderUI({ selectInput("team","Home Team",choices = unique(IPL %>% filter(season == input$season_team) %>% select(team1))) }) }
answered Oct 28 by anonymous
• 32,260 points

Related Questions In Data Analytics

0 votes
1 answer
0 votes
0 answers

How to set the width of navlistPanel in Shiny? - R

How to set the width of navlistPanel ...READ MORE

Jul 18 in Data Analytics by ramya
145 views
0 votes
1 answer

How to write a custom function which will replace all the missing values in a vector with the mean of values in R?

Consider this vector: a<-c(1,2,3,NA,4,5,NA,NA) Write the function to impute ...READ MORE

answered Jul 4, 2018 in Data Analytics by CodingByHeart77
• 3,690 points
218 views
0 votes
1 answer

How to reduce the height of valueBox in shiny R?

Add this line before using your vlaueBoxes tags$head(tags$style(HTML(".small-box ...READ MORE

answered Dec 4, 2018 in Data Analytics by Haseeb
598 views
0 votes
1 answer

Error saying "could not find function "shinyUI"" in shiny R

Its a small spelling mistake that you've ...READ MORE

answered Nov 28, 2018 in Data Analytics by Maverick
• 10,040 points
501 views
0 votes
1 answer

Error saying "could not find function dashboardPage" in shiny R

Include this line in the code: Library(shinydashboard) READ MORE

answered Nov 28, 2018 in Data Analytics by Maverick
• 10,040 points
308 views
0 votes
1 answer

How to render outputs of few elements(graphs) in shiny app?

hi Racheal, You can isolate those outputs which ...READ MORE

answered Aug 30 in Data Analytics by anonymous
• 32,260 points
16 views
0 votes
1 answer

How to include css code in shiny r app?

To include a CSS file, use includeCSS(), ...READ MORE

answered Aug 30 in Data Analytics by anonymous
• 32,260 points
132 views