I am tring to make a chekbox to be able to filter the dataset by years. However not every variable does have all the data for every year so i wanted only the years the variable has data for shown in the ui. Sadly after splitting my code into conditional panels the buttons do not filter any longer.
conditionalPanel(condition = "input.Select2 == 'AFD' | input.Select2 == 'Piraten'", checkboxGroupInput("Year", label = h3("Checkbox group"), choices = "2013"), selected = "2013"), conditionalPanel(condition = "input.Select2 == 'DieLinke'", checkboxGroupInput("Year", label = h3("Checkbox group"), choices = list("2009", "2013"), selected = "2013")), conditionalPanel(condition = "input.Select2 == 'Gruene' | input.Select2 == 'FDP' | input.Select2 == 'SPD' | input.Select2 == 'CDU'", checkboxGroupInput("Year", label = h3("Checkbox group"), choices = list("1998", "2002", "2005","2009", "2013"), selected = "2013"))
Does anyone know why?
example of plot being generated in the server fucntion:
dfParteien %>%
filter(Partei %in% chosen_party) %>%
filter(Jahr %in% input$Year) %>%
count(word) %>%
with(wordcloud(word, n, max.words = input$Slider1, colors=pal12))
Aucun commentaire:
Enregistrer un commentaire