Shiny中一个有趣的例子是US map。我想为荷兰Dutch shapes的邮政编码实施它,并创建一个简单的专题地图。
library(maptools)
readshp<-readShapeSpatial("C:/R/census-app/ESRI-PC4-2015R1.shp")
我想在其中创建地图的变量添加到形状后面的Dbasefile中,但是之后:
map("readshp", fill = TRUE, col = fills,
resolution = 0, lty = 0, projection = "polyconic",
myborder = 0, mar = c(0,0,0,0))
R显示错误:
get(dbname)中的错误:object&#39; readshpMapEnv&#39;找不到
我们如何解决这个问题?
答案 0 :(得分:0)
我猜这是由于报价。删除对象周围的引号。尝试:
map(readshp, fill = TRUE, col = fills,
resolution = 0, lty = 0, projection = "polyconic",
myborder = 0, mar = c(0,0,0,0))
此外..下次“包含足够的代码以允许其他人重现问题..”请参阅How do I ask a good question?;)