问题描述
我希望从这里使用此amCharts库来实现一些可视化。 https://www.amcharts.com/demos/grouped-countries-map/
我已经序列化了我的数据表,但似乎无法正常工作,我不确定如何对4个类别/地区进行分组。
任何帮助/建议都是很好的帮助。
var groupData = [
{
"name": "EU member before 2004","color": chart.colors.getIndex(0),"data": [
{
"title": "Austria","id": "AT",// With MappolygonSeries.useGeodata = true,it will try and match this id,then apply the other properties as custom data
"customData": "1995"
},{
"title": "Ireland","id": "IE","customData": "1973"
},{
"title": "Denmark","id": "DK",{
"title": "Portugal","id": "PT","customData": "1986"
}
]
},{
"name": "Joined at 2004","color": chart.colors.getIndex(1),"data": [
{
"title": "Lithuania","id": "LT","customData": "2004","groupId": "2004"
},{
"title": "Latvia","id": "LV","groupId": "2004"
}
},{
"name": "Joined at 2007","color": chart.colors.getIndex(3),"data": [
{
"title": "Romania","id": "RO","customData": "2007"
},{
"title": "Bulgaria","id": "BG","customData": "2007"
}
]
},{
"name": "Joined at 2013","color": chart.colors.getIndex(4),"data": [
{
"title": "Croatia","id": "HR","customData": "2013"
}
]
}
];
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)