Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- tags$script(HTML("var header = $('.navbar > .container');
- header.append('<div Company name text here>')"))
- library(shiny)
- server <- function(input, output, session) {
- output$plot <- renderPlot({
- plot(cars, type=input$plotType)
- })
- output$summary <- renderPrint({
- summary(cars)
- })
- output$table <- DT::renderDataTable({
- DT::datatable(cars)
- })
- }
- ui <-shinyUI(navbarPage("Navbar!",
- tabPanel("Plot",
- sidebarLayout(
- sidebarPanel(
- radioButtons("plotType", "Plot type",
- c("Scatter"="p", "Line"="l")
- )
- ),
- mainPanel(
- plotOutput("plot")
- )
- )
- ),
- tabPanel("Summary",
- verbatimTextOutput("summary")
- ),
- tags$script(HTML("var header = $('.navbar > .container');
- header.append('<div style="float:right"><h3>Company name text here</h3></div>');
- console.log(header)"))
- ))
- shinyApp(ui = ui, server = server)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement