Reputation: 1447
I have a shiny app like this:
library(shiny)
UI <- fluidPage(
numericInput("obs", "Observations:", 10, min = 1, max = 100),
numericInput("obs", "Observations:", 10, min = 1, max = 100)
)
Server <- function(input, output) {}
shinyApp(ui = UI, server = Server)
If i remove the titles like this:
UI <- fluidPage(
numericInput("obs", "", 10, min = 1, max = 100),
numericInput("obs", "", 10, min = 1, max = 100)
)
Server <- function(input, output) {}
shinyApp(ui = UI, server = Server)
I still have white space floating above the input fields. Any thoughts on how i an get rid of this?
Upvotes: 3
Views: 1536
Reputation: 28339
Use NULL
as label if you want empty field:
library(shiny)
UI <- fluidPage(
numericInput("obs", "Observations:", 10, min = 1, max = 100),
numericInput("obs", "", 10, min = 1, max = 100),
numericInput("obs", NULL, 10, min = 1, max = 100)
)
Server <- function(input, output) {}
shinyApp(ui = UI, server = Server)
Upvotes: 8