我有一个如下图所示设计的UI,我想在这里设置一个条件:
选择/检查方框" Saddle Joint"在侧边栏location
,我想要选项" GEO_10500"," GEO_77298"从侧栏Datasets:
中选择。这是我尝试过的服务器代码,但它没有用。让我知道如何实现这一目标。谢谢!
Server.R
conditionalPanel(
condition = "input.location = 'Saddle Joint'",
updateCheckboxGroupInput(session,
"datasets",
"Datasets:",
choices=c("GEO_10500", "GEO_77298"),
selected = "GEO_10500"
)
)
Server.R
`
observe({
if ("input.location== 'Saddle Joint'") {
updateCheckboxGroupInput(session,
"datasets", "Datasets:", choices = c("GEO_15602","GEO_21537"),
selected= c("GEO_15602","GEO_21537"))
}
})
`