gvisGeoChart 中的 ISO 代码不正确?

Incorrect ISO codes in gvisGeoChart?

我刚开始在 R 中使用 googleVis,运行 遇到了一些麻烦。我想制作洪都拉斯各省的等值线图;这是我的代码:

map_me <- data.frame(prov=c("HN-AT","HN-CH","HN-CL","HN-CM","HN-CP","HN-CR",
                            "HN-EP","HN-FM","HN-GD","HN-IB","HN-IN","HN-LE",
                            "HN-LP","HN-OC","HN-OL","HN-SB","HN-VA","HN-YO"),
                     x=c(0.47,0.32,0.31,0.25,0.24,0.41,0.40,0.38,0.43,0.29,
                         0.17,0.25,0.33,0.17,0.19,0.39,0.21,0.31))
g <- gvisGeoChart(map_me,locationvar='prov',colorvar='x',
                  options=list(region="HN",dataMode="regions"))
plot(g)

在弹出的浏览器 window 中,地图正确放大了洪都拉斯,图例中的色标显示了正确的范围 (0.17-0.47)。我想我有正确的 ISO 3116-2 代码,基于 Wikipedia entry,但似乎无法将我的数据连接到地图位置。

有什么想法吗?

当所有其他方法都失败时,请阅读 vignette。原来我需要设置正确的分辨率选项:

g <- gvisGeoChart(map_me,locationvar='prov',colorvar='x',
                  options=list(region="HN",resolution="provinces"))