R shiny dashboard output panel issue












0














I have created the following dashboard in shiny



I first import the folloiwng libraries in R



 library(shinydashboard)
library(shiny)
library(DT)
library(shinyWidgets)
library(readxl)


We first create the UI here to provide an date, fileimport, a nmeric input and an action button



  ui=shinyUI(
dashboardPage(
dashboardHeader(

title = "Chart",
titleWidth = 850
),
dashboardSidebar(


# Change font size here



tags$head(
tags$style(HTML(".main-sidebar { font-size: 20px; }"), style =
"background-color: #78d9c9;") #change the font size to 20
),



fileInput(inputId = "file", label = 'Load Dataset Here',placeholder =
"Upload",
multiple = TRUE,
accept = c("xlsx/xls",".xls",".xlsx"), width = "100%"),
dateInput(inputId = 'Cutoffdate',label = 'Cut Off date'),

numericInput(inputId = 'AAA',label = 'AAA', value = 0, min = 0, max =
120, step = 6),# Add new font color here

actionButton(inputId = 'Button',label ='Generate Chart', style="color:
#fff; background-color: #599AC3; border-color: #2e6da4, :font-color:
black")
),
dashboardBody(

tags$head(tags$style(HTML('
/* logo */
.skin-blue .main-header .logo {
background-color: #7CFC00;
}

/* logo when hovered */
.skin-blue .main-header .logo:hover {
background-color: #7CFC00;
}

/* navbar (rest of the header) */
.skin-blue .main-header .navbar {
background-color: #7CFC00;
}

# Sidebar color here
/* main sidebar */
.skin-blue .main-sidebar {
background-color: #F4A460;
}

/* active selected tab in the sidebarmenu */
.skin-blue .main-sidebar .sidebar .sidebar-menu
.active a{
background-color: #FFF8DC;
}

/* other links in the sidebarmenu */
.skin-blue .main-sidebar .sidebar .sidebar-menu
a{
background-color: #FFF8DC;
color:#A9A9A9;
}

/* other links in the sidebarmenu when hovered
*/
.skin-blue .main-sidebar .sidebar .sidebar-menu
a:hover{
background-color: #FFF8DC;
}
/* toggle button when hovered */
.skin-blue .main-header .navbar .sidebar-
toggle:hover{
background-color: #FFF8DC;
}

/* body */
.content-wrapper, .right-side {
background-color: #FFF8DC;
}

'))



),

mainPanel(

fluidRow(
column(12,plotlyOutput("plot1" , height = 600,
width=1200))

), fluidRow( column(7,tableOutput(outputId =
"Table2"))),



fluidRow(column(12,dataTableOutput(outputId =
"Table1")))


)


)


)
)


Next we create a server



     server<-function(input, output){


output$Table1<-renderDataTable({airquality})

#output$plot1<-renderPlot({hist(airquality$Ozone)})

output$Table2<-renderTable({airquality})




}
shinyApp(ui, server =server)


The color background in the main panel is not extending all the way down. The second table is set against a white background. Is there a way to expand the outputpanel size to do this










share|improve this question



























    0














    I have created the following dashboard in shiny



    I first import the folloiwng libraries in R



     library(shinydashboard)
    library(shiny)
    library(DT)
    library(shinyWidgets)
    library(readxl)


    We first create the UI here to provide an date, fileimport, a nmeric input and an action button



      ui=shinyUI(
    dashboardPage(
    dashboardHeader(

    title = "Chart",
    titleWidth = 850
    ),
    dashboardSidebar(


    # Change font size here



    tags$head(
    tags$style(HTML(".main-sidebar { font-size: 20px; }"), style =
    "background-color: #78d9c9;") #change the font size to 20
    ),



    fileInput(inputId = "file", label = 'Load Dataset Here',placeholder =
    "Upload",
    multiple = TRUE,
    accept = c("xlsx/xls",".xls",".xlsx"), width = "100%"),
    dateInput(inputId = 'Cutoffdate',label = 'Cut Off date'),

    numericInput(inputId = 'AAA',label = 'AAA', value = 0, min = 0, max =
    120, step = 6),# Add new font color here

    actionButton(inputId = 'Button',label ='Generate Chart', style="color:
    #fff; background-color: #599AC3; border-color: #2e6da4, :font-color:
    black")
    ),
    dashboardBody(

    tags$head(tags$style(HTML('
    /* logo */
    .skin-blue .main-header .logo {
    background-color: #7CFC00;
    }

    /* logo when hovered */
    .skin-blue .main-header .logo:hover {
    background-color: #7CFC00;
    }

    /* navbar (rest of the header) */
    .skin-blue .main-header .navbar {
    background-color: #7CFC00;
    }

    # Sidebar color here
    /* main sidebar */
    .skin-blue .main-sidebar {
    background-color: #F4A460;
    }

    /* active selected tab in the sidebarmenu */
    .skin-blue .main-sidebar .sidebar .sidebar-menu
    .active a{
    background-color: #FFF8DC;
    }

    /* other links in the sidebarmenu */
    .skin-blue .main-sidebar .sidebar .sidebar-menu
    a{
    background-color: #FFF8DC;
    color:#A9A9A9;
    }

    /* other links in the sidebarmenu when hovered
    */
    .skin-blue .main-sidebar .sidebar .sidebar-menu
    a:hover{
    background-color: #FFF8DC;
    }
    /* toggle button when hovered */
    .skin-blue .main-header .navbar .sidebar-
    toggle:hover{
    background-color: #FFF8DC;
    }

    /* body */
    .content-wrapper, .right-side {
    background-color: #FFF8DC;
    }

    '))



    ),

    mainPanel(

    fluidRow(
    column(12,plotlyOutput("plot1" , height = 600,
    width=1200))

    ), fluidRow( column(7,tableOutput(outputId =
    "Table2"))),



    fluidRow(column(12,dataTableOutput(outputId =
    "Table1")))


    )


    )


    )
    )


    Next we create a server



         server<-function(input, output){


    output$Table1<-renderDataTable({airquality})

    #output$plot1<-renderPlot({hist(airquality$Ozone)})

    output$Table2<-renderTable({airquality})




    }
    shinyApp(ui, server =server)


    The color background in the main panel is not extending all the way down. The second table is set against a white background. Is there a way to expand the outputpanel size to do this










    share|improve this question

























      0












      0








      0







      I have created the following dashboard in shiny



      I first import the folloiwng libraries in R



       library(shinydashboard)
      library(shiny)
      library(DT)
      library(shinyWidgets)
      library(readxl)


      We first create the UI here to provide an date, fileimport, a nmeric input and an action button



        ui=shinyUI(
      dashboardPage(
      dashboardHeader(

      title = "Chart",
      titleWidth = 850
      ),
      dashboardSidebar(


      # Change font size here



      tags$head(
      tags$style(HTML(".main-sidebar { font-size: 20px; }"), style =
      "background-color: #78d9c9;") #change the font size to 20
      ),



      fileInput(inputId = "file", label = 'Load Dataset Here',placeholder =
      "Upload",
      multiple = TRUE,
      accept = c("xlsx/xls",".xls",".xlsx"), width = "100%"),
      dateInput(inputId = 'Cutoffdate',label = 'Cut Off date'),

      numericInput(inputId = 'AAA',label = 'AAA', value = 0, min = 0, max =
      120, step = 6),# Add new font color here

      actionButton(inputId = 'Button',label ='Generate Chart', style="color:
      #fff; background-color: #599AC3; border-color: #2e6da4, :font-color:
      black")
      ),
      dashboardBody(

      tags$head(tags$style(HTML('
      /* logo */
      .skin-blue .main-header .logo {
      background-color: #7CFC00;
      }

      /* logo when hovered */
      .skin-blue .main-header .logo:hover {
      background-color: #7CFC00;
      }

      /* navbar (rest of the header) */
      .skin-blue .main-header .navbar {
      background-color: #7CFC00;
      }

      # Sidebar color here
      /* main sidebar */
      .skin-blue .main-sidebar {
      background-color: #F4A460;
      }

      /* active selected tab in the sidebarmenu */
      .skin-blue .main-sidebar .sidebar .sidebar-menu
      .active a{
      background-color: #FFF8DC;
      }

      /* other links in the sidebarmenu */
      .skin-blue .main-sidebar .sidebar .sidebar-menu
      a{
      background-color: #FFF8DC;
      color:#A9A9A9;
      }

      /* other links in the sidebarmenu when hovered
      */
      .skin-blue .main-sidebar .sidebar .sidebar-menu
      a:hover{
      background-color: #FFF8DC;
      }
      /* toggle button when hovered */
      .skin-blue .main-header .navbar .sidebar-
      toggle:hover{
      background-color: #FFF8DC;
      }

      /* body */
      .content-wrapper, .right-side {
      background-color: #FFF8DC;
      }

      '))



      ),

      mainPanel(

      fluidRow(
      column(12,plotlyOutput("plot1" , height = 600,
      width=1200))

      ), fluidRow( column(7,tableOutput(outputId =
      "Table2"))),



      fluidRow(column(12,dataTableOutput(outputId =
      "Table1")))


      )


      )


      )
      )


      Next we create a server



           server<-function(input, output){


      output$Table1<-renderDataTable({airquality})

      #output$plot1<-renderPlot({hist(airquality$Ozone)})

      output$Table2<-renderTable({airquality})




      }
      shinyApp(ui, server =server)


      The color background in the main panel is not extending all the way down. The second table is set against a white background. Is there a way to expand the outputpanel size to do this










      share|improve this question













      I have created the following dashboard in shiny



      I first import the folloiwng libraries in R



       library(shinydashboard)
      library(shiny)
      library(DT)
      library(shinyWidgets)
      library(readxl)


      We first create the UI here to provide an date, fileimport, a nmeric input and an action button



        ui=shinyUI(
      dashboardPage(
      dashboardHeader(

      title = "Chart",
      titleWidth = 850
      ),
      dashboardSidebar(


      # Change font size here



      tags$head(
      tags$style(HTML(".main-sidebar { font-size: 20px; }"), style =
      "background-color: #78d9c9;") #change the font size to 20
      ),



      fileInput(inputId = "file", label = 'Load Dataset Here',placeholder =
      "Upload",
      multiple = TRUE,
      accept = c("xlsx/xls",".xls",".xlsx"), width = "100%"),
      dateInput(inputId = 'Cutoffdate',label = 'Cut Off date'),

      numericInput(inputId = 'AAA',label = 'AAA', value = 0, min = 0, max =
      120, step = 6),# Add new font color here

      actionButton(inputId = 'Button',label ='Generate Chart', style="color:
      #fff; background-color: #599AC3; border-color: #2e6da4, :font-color:
      black")
      ),
      dashboardBody(

      tags$head(tags$style(HTML('
      /* logo */
      .skin-blue .main-header .logo {
      background-color: #7CFC00;
      }

      /* logo when hovered */
      .skin-blue .main-header .logo:hover {
      background-color: #7CFC00;
      }

      /* navbar (rest of the header) */
      .skin-blue .main-header .navbar {
      background-color: #7CFC00;
      }

      # Sidebar color here
      /* main sidebar */
      .skin-blue .main-sidebar {
      background-color: #F4A460;
      }

      /* active selected tab in the sidebarmenu */
      .skin-blue .main-sidebar .sidebar .sidebar-menu
      .active a{
      background-color: #FFF8DC;
      }

      /* other links in the sidebarmenu */
      .skin-blue .main-sidebar .sidebar .sidebar-menu
      a{
      background-color: #FFF8DC;
      color:#A9A9A9;
      }

      /* other links in the sidebarmenu when hovered
      */
      .skin-blue .main-sidebar .sidebar .sidebar-menu
      a:hover{
      background-color: #FFF8DC;
      }
      /* toggle button when hovered */
      .skin-blue .main-header .navbar .sidebar-
      toggle:hover{
      background-color: #FFF8DC;
      }

      /* body */
      .content-wrapper, .right-side {
      background-color: #FFF8DC;
      }

      '))



      ),

      mainPanel(

      fluidRow(
      column(12,plotlyOutput("plot1" , height = 600,
      width=1200))

      ), fluidRow( column(7,tableOutput(outputId =
      "Table2"))),



      fluidRow(column(12,dataTableOutput(outputId =
      "Table1")))


      )


      )


      )
      )


      Next we create a server



           server<-function(input, output){


      output$Table1<-renderDataTable({airquality})

      #output$plot1<-renderPlot({hist(airquality$Ozone)})

      output$Table2<-renderTable({airquality})




      }
      shinyApp(ui, server =server)


      The color background in the main panel is not extending all the way down. The second table is set against a white background. Is there a way to expand the outputpanel size to do this







      r shiny shinydashboard






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Nov 20 at 5:07









      Raghavan vmvs

      15411




      15411
























          1 Answer
          1






          active

          oldest

          votes


















          0














          The solution is simple. One needs to just remove mainpanel() in the UI.






          share|improve this answer





















            Your Answer






            StackExchange.ifUsing("editor", function () {
            StackExchange.using("externalEditor", function () {
            StackExchange.using("snippets", function () {
            StackExchange.snippets.init();
            });
            });
            }, "code-snippets");

            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "1"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














            draft saved

            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53386553%2fr-shiny-dashboard-output-panel-issue%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            0














            The solution is simple. One needs to just remove mainpanel() in the UI.






            share|improve this answer


























              0














              The solution is simple. One needs to just remove mainpanel() in the UI.






              share|improve this answer
























                0












                0








                0






                The solution is simple. One needs to just remove mainpanel() in the UI.






                share|improve this answer












                The solution is simple. One needs to just remove mainpanel() in the UI.







                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Nov 20 at 5:43









                Raghavan vmvs

                15411




                15411






























                    draft saved

                    draft discarded




















































                    Thanks for contributing an answer to Stack Overflow!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.





                    Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


                    Please pay close attention to the following guidance:


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53386553%2fr-shiny-dashboard-output-panel-issue%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    "Incorrect syntax near the keyword 'ON'. (on update cascade, on delete cascade,)

                    Alcedinidae

                    Origin of the phrase “under your belt”?