我正在尝试将外部属性添加到 topojson 文件中(us-counties.json
使用us-atlasmake topo/us-counties.json
制作)。我正在处理这个例子。但是我生成的 topojson 文件us-counties-with-population.json
根本没有任何属性。
我的电话看起来像:
topojson --external-properties data.csv \
--id-property id_county \
--properties population=+percent_population \
-o us-counties-with-population.json \
-- us-counties.json
我的数据看起来像(head -n5 data.csv
):
id_county,county_name,percent_population
01003,"Baldwin County, Alabama",9.71576144493279
01043,"Cullman County, Alabama",6.734653334216277
01051,"Elmore County, Alabama",7.095232589509385
01069,"Houston County, Alabama",9.857459440234194
我正在使用 topojson v1.2.2。我想我可能遗漏了一些与 id 匹配方式相关的内容,但我不确定它是什么。