Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/r/71.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
R 无法在闪亮的仪表板中增加AM漏斗图的宽度_R_Shiny_Amcharts_Shinydashboard - Fatal编程技术网

R 无法在闪亮的仪表板中增加AM漏斗图的宽度

R 无法在闪亮的仪表板中增加AM漏斗图的宽度,r,shiny,amcharts,shinydashboard,R,Shiny,Amcharts,Shinydashboard,我正在尝试构建一个小的仪表板应用程序,其中我需要使用ramcharts的amfunnel绘制漏斗图。请参阅下面的代码和屏幕截图 body <- dashboardBody( tags$style(type = "text/css", "#map {height: calc(100vh - 80px) !important;}"), fluidRow( box( title = "Box title", width = 6, status = "primary",

我正在尝试构建一个小的仪表板应用程序,其中我需要使用ramcharts的amfunnel绘制漏斗图。请参阅下面的代码和屏幕截图

body <- dashboardBody(
  tags$style(type = "text/css", "#map {height: calc(100vh - 80px) !important;}"),
  fluidRow(
    box(
      title = "Box title", width = 6, status = "primary",
      amChartsOutput(outputId = "amfunnel",width = "100%")
    ),
    box(
      status = "warning", width = 4,
      "Box content"
    ),
    box(
      status = "warning", width = 2, 
      "Box Content"
    )

  )
)  
server <- function(input, output) {
  output$amfunnel <-  renderAmCharts({
    amFunnel(data = data_funnel, inverse = FALSE, label_side = "left")
  })

body参考
amFunnel
的文档后,您只需使用边距参数:

amFunnel(data = data_funnel, inverse = FALSE, margin_right = 0, label_side = 'left')

我不太清楚你在找什么。图表的顶部(蓝色部分)是否应该与它所嵌入的框具有相同的宽度?是的,它与框具有相同的宽度。我要找的是更改尺寸或调整由amfunnel创建的绘图的大小。@MartinSchmelzer如果您看到漏斗绘图非常窄,并且框中漏斗绘图周围有大量空白。所以我想增加宽度/加宽漏斗图,这样图看起来会很漂亮,并且填充整个方框使用边距参数不起作用<代码>amFunnel(数据=data\U funnel,反向=FALSE,边距右=0,边距左=190,标签边=left')
谢谢@MartinSchmelzer它成功了。。。非常感谢您的解决方案。