Hello,
this is my code:absolutePanel(id = "states", class = "panel panel-default", fixed = TRUE,
draggable = TRUE, top = 60, left = "auto", right = 20, bottom = "auto",
width = 200, height = "auto",
selectizeInput(inputId = "z",
label = "Area",
choices = c("select an area"="","USA","Regions","State"),
uiOutput("uil")
)))
)
server <- function(input, output,session) {
output$uil<-renderUI({
switch(input$z,
"State"= selectizeInput(
"st", "State",
choices =c("select a state"="",state.name)),
"Regions"=selectizeInput(
"rig", "Region",
choices = c("select a region"="",unique(m$Region)))
})
i know i put in my placeholder a string, select a region, or select a state which ="". whenever i switch my input , for example from regions to state , my last plot disappear and this error appears: invalid 'type' (list) of argument .
when a choose an input, for example a state or region from the list , my plot appear.
- how can i isolate the dependency of NULL or "" value ?
- how can i keep my plot till i choose an input from the list.
thank you