shinydashboard

Render Box Dynamically in Shiny

北城以北 提交于 2019-12-06 16:06:07
how to render a box in shiny according to the data. data is uploaded by user and it can have more data than this, so i have to create a box dynamically. i am running the below code and i am getting four box created in console not in shiny webpage. please have a look, thankyou. CODE list_data <- list(c("AB","CD","EF","GH")) #data ui <- dashboardPage( dashboardHeader(title = "Text Mining"), dashboardSidebar( sidebarMenu( menuItem("NLP Tree", tabName = "NLP") ) ), dashboardBody( tabItems( tabItem(tabName = "NLP", fluidRow( tabBox(width = 12,height="500", tabPanel("Sentences", uiOutput("nlp

R shiny Dashboard : Exceed the bootstrap width = 12 and add an horizontal scrollbar

荒凉一梦 提交于 2019-12-06 15:31:58
问题 I'm currently learning to use R shiny dashboard. I'm using fluidrow(column(...)) to do my page layout. I'm currently facing a problem: I can't put as much elements as I would like in a row. Basically, I would like to put a lot of elements on the same line with an horizontal scrollbar. example: library(shiny) library(shinydashboard) header <- dashboardHeader(title = "My Dashboard") sidebar <- dashboardSidebar( sidebarMenu( id = "tabs", menuItem("My Tab", tabName = "my_Tab", icon = icon("th"))

R shinydashboard - show/hide multiple menuItems based on user input

≡放荡痞女 提交于 2019-12-06 14:47:22
问题 The idea is to have a user input (access code), based on which different menuItems can be accessed. So basically we have a custom version of app available based on user's requirement. A working example for 3 menuItems is as follow: library(shiny) library(shinydashboard) library(shinyjs) ui <- dashboardPage( dashboardHeader(title = "SHOW/HIDE MULTIPLE MENU ITEMS"), dashboardSidebar( useShinyjs(), sidebarMenu( id = "tabs", hidden( menuItem("MENU ITEM 1", tabName = "mi1"), menuItem("MENU ITEM 2"

How can I add logo besides project name in shiny dashboard?

我的未来我决定 提交于 2019-12-06 11:31:07
Please can you help me to add company logo on the left top of shiny dashboard besides project name. I have tried to use the code in the other answers here on stackoverflow but still can't solve my problem. I am a total ignorant in HTML and css. Here is my code: library(shiny) library(shinydashboard) shinyApp( ui = dashboardPage(skin = "green", dashboardHeader(title = "Project name", # this could show the logo but not where I wanted ! tags$li(a(href = 'http://www.company.com', img(src = 'logo.jpg', title = "Company Home", height = 30px"), style = "padding-top:10px; padding-bottom:10px;"), class

R Shiny - Optimize page loading time with updateSelectizeInput

巧了我就是萌 提交于 2019-12-06 09:34:11
Our shiny page has multiple selectizeInput controls, and some of them have long lists in their drop-down boxes. Because of this, the initial loading time is very long as it needs to pre-fill drop-down boxes for all selectizeInput controls. Edit: Please see below example showing how loading long lists impacts page loading time. Please copy below codes and run directly to see loading process. library(shiny) library(shinydashboard) ui <- dashboardPage( dashboardHeader(title = "Basic dashboard"), dashboardSidebar( selectizeInput("a","filter 1",choices = sample(1:100000, 10000),multiple = T),

Align header elements in shiny dashboard

眉间皱痕 提交于 2019-12-06 08:42:57
问题 I'm working with shinydashboard to jazz up a shiny app a bit and I'm having trouble positioning some elements (eg logo) on the page. I found this answer which was immensely useful in increasing the height of the header, but I can't quite manage the alignment issue. There are still spaces on the left and right (red ovals) between the logo and the floating hamburger and the edges. The only way I've been able to move the hamburger has been increasing the relative size ( titleWidth = "92%" ) of

How to use the download button in Shiny?

此生再无相见时 提交于 2019-12-06 07:04:37
I want to download a csv file using the download button in Shiny. The file would be created using the parameters from a secondary r script. ###SERVER output$downloadData <- downloadHandler({ filename = function() { paste('data-', Sys.Date(), '.csv', sep='') } content = function(file) { csv_write<-array(0,dim=c(length(GHI_D),15)) csv_write<-cbind(GHI_Data$timeStamp,GHI_D,POA_OBS_T,POA_model_T,POA_model_FT,POA_OBS,DNI_model,DHI,tracking_angle,incidence_angel_T,Backtracking_angle,SunAz,SunEl,Kt,DNI,DDNI,incidence_angel,DHI_model,DHI_model_T,Eb,Eb_T) write.csv(csv_write,row.names=FALSE, na="")

Add coordinates to image for use as map in Leaflet, Shiny and Shinydashboard packages in R

杀马特。学长 韩版系。学妹 提交于 2019-12-06 06:18:41
问题 I am planning to create an interactive map with markers of hospital OHS incidents using Leaflet, Shiny and Shinydashboard along the lines of the following awesome template for interactive map and histogram My problem is that I do not have a coordinate reference system as this is not a geographic object (no lat and long). Also it is in raster form. How can I make the below floorplan into something with a CRS (coordinate reference system) that can be treated like a map. That is, I want to be

How to manage my R code in a shiny or shinydashboard app?

て烟熏妆下的殇ゞ 提交于 2019-12-06 04:11:05
I have made a shinydashboard app which has now quite an amount of lines of code, and I am wondering if there are ways to split the code into different . R files. I have seen a similar question here , but the answer does not help (especially it says nothing about the code in the server part of the app). For the ui part, I have created functions called header , sidebar , and body , and then I merely write ui <- dashboardPage(header(), sidebar(), body()) It works well, and it still works if the functions header , sidebar , and body need to have arguments. For the server part, I don't think a

sliderInput Max/Min Text Labels

半世苍凉 提交于 2019-12-06 03:20:55
问题 I am currently working on a dashboard with multiple sliderInputs. Is it possible to replace the max and min labels with text? For example, my min = 1 and max = 10. I want to keep the scale from 1 to 10 while having the slider labels appear as "sooner" and "later" respectively. Thanks! 回答1: The short answer here is no, sadly; short of hacking through the underlying code in JavaScript, there is no way to relabel slider ticks (though there are a few formatting parameters). However, you can hack