dashboardSidebar:页面大小

时间:2016-12-29 08:32:56

标签: shiny shinydashboard

enter image description here

有人可以帮我解决这个显示问题吗?

2 个答案:

答案 0 :(得分:0)

ui <-  dashboardPage(
  skin = "red",
  dashboardHeader(title = "TEXT MINING", disable = F),
  dashboardSidebar(
    tags$style(
      "text/css",
      ".navbar {background-color:bule;}",
      "html,body,#map  body {width:120%;height:100%}"
    ),
    br(),
    br(),
    br(),
    br(),

    tags$head(tags$style(
      ".wrapper {overflow: visible !important;}"
    )),

    selectInput("choix", h2("ALL vs PRIO"), c("ALL", "PRIO")),
    helpText("ALL= Tout les clients, PRIO= Clients séléctionés(Prioritaires)"),
    selectInput("w", h2("Pondération de la matrice "), c("Tf", "TfIdf")),
    br(),
    br(),
    br(),
    br(),
    helpText("Cliquer pour téléharger la table"),
    downloadButton('downloadData', 'Download'),
    br(),
    br(),
    br(),
    br(),
    br(),
    br(),
    br(),
    br()

  ),
  dashboardBody(mainPanel(tabsetPanel(
    navbarPage(
      "",
      tabPanel("Données", icon = icon("database"), dataTableOutput('donnees')),
      tabPanel(
        "Analyses exploratoires",
        icon = icon("bar-chart"),

        box(
          title = "Les pages visitées",
          status = "warning",
          width = 25,
          solidHeader = TRUE,
          collapsible = TRUE,
          plotOutput("pages", height = "650px")
        ),

        box(
          title = "Histogramme des notations ",
          status = "warning",
          width = 25,
          solidHeader = TRUE,
          collapsible = TRUE,
          plotOutput("his", height = "650px")
        ),

        box(
          title = "score par nombre d'étoile",
          status = "warning",
          width = 25,
          solidHeader = TRUE,
          collapsible = TRUE,
          plotOutput("sc", height = "650px")
        ) ,

        box(
          title = "Mots fréquents",
          status = "warning",
          width = 25,
          solidHeader = TRUE,
          collapsible = TRUE,
          plotOutput("mots", height = "650px")
        )



      ),
      tabPanel(
        "Nuages et assosciations des mots ",
        icon = icon("cloud"),
        fluidRow(column(12, wellPanel(
          sliderInput(
            "max",
            "Nombre maximal de mots",
            min = 100,
            max = 300,
            value = 200,
            step = 10
          )
        )),
        column(
          12,

          box(
            title = "Word Cloud",
            status = "warning",
            width = 18,
            solidHeader = TRUE,
            collapsible = TRUE,
            plotOutput("nuage", height = "450px")
          )
        )),
        fluidRow(column(12, wellPanel(
          sliderInput(
            "lowf",
            "Choisir n tel que Fréquence(mots)>n",
            min = 5,
            max = 30,
            value = 10,
            step = 1
          )
        )),
        column(
          12,
          box(
            title = "Graphe des associations",
            status = "warning",
            width = 18,
            solidHeader = TRUE,
            collapsible = T,
            plotOutput("asso", height = "650px")
          )
        ))
      ),
      tabPanel("Clustering", icon = icon("sitemap"), fluidRow(column(
        12,
        box(
          title = "K-means",
          status = "warning",
          width = 30,
          solidHeader = TRUE,
          collapsible = TRUE,
          plotOutput("cl", height = "650px")
        )
      ),
      column(
        12,
        box(
          title = "CAH",
          status = "warning",
          width = 30,
          solidHeader = TRUE,
          collapsible = TRUE,
          plotOutput("cl2", height = "650px")
        )
      ))),
      tabPanel(
        "Rapport",
        icon = icon("book") ,
        tags$iframe(style = "height:800px; width:100%; scrolling=yes",
                    src =
                      "rapportTextMining.pdf")
      )
    )
  ))))

答案 1 :(得分:0)

这取决于您使用的布局。如果您使用基于列的布局,则可以设置box(width=NULL)。这应该解决问题。从您的代码看起来您​​正在使用基于列的布局。 width =25没有意义。因为,are的总宽度是12.因此,将其设置为width = NULL,它将解决问题。 如果您正在使用基于行的布局,那么当您弄乱宽度参数时。

相关问题