尝试部署闪亮的应用程序时出现错误。
它在本地运行良好,但是在尝试部署它时出现错误。
这是代码
library(shiny)
library(tidyverse)
library(leaflet)
rsconnect::deployApp('/Users/tylerreifsteck/Desktop/Marketing ChangeLab/new_app2')
EVILLE<- read_csv("mappingdata.csv")
ui<- bootstrapPage(
tags$style(type = "text/css", "html, body {width:100%;height:100%}"),
leafletOutput("plot", width = "100%", height = "100%")
)
server<- function(input, output) {
output$plot <- renderLeaflet({
leaflet() %>% addTiles() %>%
addMarkers(data = EVILLE, lng = ~long, lat = ~lat, popup = paste("Company:", dat$`Company Name`, "<br>",
"Contact:", dat$`Full Name of Contact`, "<br>",
"Phone:", dat$Phone, "<br>",
"Address:", dat$address, "<br>",
"Business Type:", dat$`Primary NAICS 6 Digit Description`))
})
}
shinyApp(ui = ui, server = server)
我收到的错误是:
值[3L]中的错误:“关闭”类型的对象不可子集化
我已经研究了错误,但是找不到解决问题的方法。