shiny Error in match.arg(position) : 'arg' must be NULL or a character vector

前端 未结 1 1020
清歌不尽
清歌不尽 2021-01-19 05:53

I went into an error when running my shiny app. The error seems in ui.R but I have checked so many times and still can\'t figure it out. Does anyone have ideas? Here\'s my c

相关标签:
1条回答
  • 2021-01-19 06:41

    It's in your call to sidebarLayout (it's in your error message trace). If you look at ?sidebarLayout, it takes 4 arguments

    function (sidebarPanel, mainPanel, position = c("left", "right"), 
        fluid = TRUE) 
    {
        position <- match.arg(position)
        ...
    

    The third argument is a string "left" or "right" being the position. Your third argument seems to be a mainPanel and you are passing in two sidebarPanels. That's why you are getting that argument.

    0 讨论(0)
提交回复
热议问题