shinydashboard

Shiny: Trigger a popup by clicking a valueBox

坚强是说给别人听的谎言 提交于 2020-06-10 02:04:13
问题 I want to display a table of data in a pop-up window by clicking on valueBox . The valueBox itself should work as an actionButton . When I click on the valueBox it should render a table in pop-up window as in the picture below. Can anyone help on this code? My code: library(shiny) library(shinydashboard) data <- iris ui <- dashboardPage( dashboardHeader(title = "Telemedicine HP"), dashboardSidebar(), dashboardBody( fluidRow( valueBox( 60, subtitle = tags$p("Attended", style = "font-size: 200%

whitespace in R Shiny

核能气质少年 提交于 2020-06-01 05:12:31
问题 I have a problem with text in Shiny Dashboard. I would like to save original text formatting, but shiny removes the whitespaces I want to keep. output$frame <- renderUI({ HTML(paste( p(strong("Name and Surname:"),(" John Smith")) ) ) }) tabItem(tabName = "aaa", h2("bbb"), fluidRow( box(width = 6, solidHeader = TRUE, htmlOutput("frame")) ) ), Unfortunately I get "Name and Surname: John Smith". I wish to have "Name and Surname: John Smith" . How to solve this problem? 回答1: You can use HTML(' ')

Right sidebar open by default in shinydashboardPlus

感情迁移 提交于 2020-05-28 05:47:25
问题 Is there any way to have right sidebar open by default in shinydashboardPlus? library(shiny) library(shinydashboard) shinyApp( ui = dashboardPagePlus( header = dashboardHeaderPlus( enable_rightsidebar = TRUE, rightSidebarIcon = "gears" ), sidebar = dashboardSidebar(), body = dashboardBody(), rightsidebar = rightSidebar( background = "dark", rightSidebarTabContent( id = 1, title = "Tab 1", icon = "desktop", active = TRUE, sliderInput( "obs", "Number of observations:", min = 0, max = 1000,

Move R Shiny showNotification to center of screen

二次信任 提交于 2020-05-25 04:47:25
问题 I am looking at customizing the showNotification() functionality from Shiny. https://gallery.shinyapps.io/116-notifications/ I would like the message to be generated in the middle of the screen as opposed to the bottom-right. I don't think this can be set natively but I am hoping someone would have a suggestion of how to accomplish this. 回答1: You can use tags$style to overwrite the CSS class properties (in this case: .shiny-notification ). You could also adjust other properties like width and

Move R Shiny showNotification to center of screen

泪湿孤枕 提交于 2020-05-25 04:47:05
问题 I am looking at customizing the showNotification() functionality from Shiny. https://gallery.shinyapps.io/116-notifications/ I would like the message to be generated in the middle of the screen as opposed to the bottom-right. I don't think this can be set natively but I am hoping someone would have a suggestion of how to accomplish this. 回答1: You can use tags$style to overwrite the CSS class properties (in this case: .shiny-notification ). You could also adjust other properties like width and

Integrate plotly with shinydashboard

血红的双手。 提交于 2020-05-13 04:43:15
问题 I have used shiny for several small scale project and am now giving a try to the shinydashboard package which looks rather promising. I also want to integrate interactive plot using plotly (although other libraries can be considered in the future). I have no problem running examples integrating plotly in shiny (example) but face problems when attempting to achieve a similar results with shinydashboard. For example, the code below (app.R) is not working properly. library(shiny) library

Call updateTabItems from inside Shiny module

倖福魔咒の 提交于 2020-04-16 12:50:07
问题 In my shiny app I have lots of valueBoxes, each representing a tabItem in the sidebar of the shinydashboard. When clicking on the valueBox the page should move to the correct tab. Instead of copypasting the code lots of times I wrote a reusable module which renders the valueBox and changes the class of the valueBox into an actionButton. In the server part I have included an observeEvent which calls updateTabItems when the valueBox is clicked. But when clicked nothing happens. It seems that

Call updateTabItems from inside Shiny module

落花浮王杯 提交于 2020-04-16 12:49:48
问题 In my shiny app I have lots of valueBoxes, each representing a tabItem in the sidebar of the shinydashboard. When clicking on the valueBox the page should move to the correct tab. Instead of copypasting the code lots of times I wrote a reusable module which renders the valueBox and changes the class of the valueBox into an actionButton. In the server part I have included an observeEvent which calls updateTabItems when the valueBox is clicked. But when clicked nothing happens. It seems that

Call updateTabItems from inside Shiny module

淺唱寂寞╮ 提交于 2020-04-16 12:47:47
问题 In my shiny app I have lots of valueBoxes, each representing a tabItem in the sidebar of the shinydashboard. When clicking on the valueBox the page should move to the correct tab. Instead of copypasting the code lots of times I wrote a reusable module which renders the valueBox and changes the class of the valueBox into an actionButton. In the server part I have included an observeEvent which calls updateTabItems when the valueBox is clicked. But when clicked nothing happens. It seems that

Display different image as title of shiny dashboard based on different tabpanels

徘徊边缘 提交于 2020-04-11 18:32:49
问题 Is it possible to display different image as title of the shiny dashboard based on the tabPanel() that you use. I want different image for the tab 'Front' and different for the tab 'Data' . # app.R ## library(shiny) library(shinydashboard) library(shinydashboardPlus) library(DT) library(shinyWidgets) library(shinyjs) dbHeader <- dashboardHeaderPlus( enable_rightsidebar = TRUE, rightSidebarIcon = "gears", fixed = T, title = tags$a(href='http://mycompanyishere.com', tags$img(src='logo.png')) )