雷达图
For Example
option = {
radar: {
indicator: [{
name: '销售(sales)',
max: 6500
}, {
name: '管理(Administration)',
max: 16000
}, {
name: '信息技术(Information Techology)',
max: 30000
}, {
name: '客服(Customer Support)',
max: 38000
}, {
name: '研发(Development)',
max: 52000
}, {
name: '市场(Marketing)',
max: 25000
}]
},
series: [{
name: '预算 vs 开销(Budget vs spending)',
type: 'radar',
data: [{
value: [4300, 10000, 28000, 35000, 50000, 19000],
name: '预算分配(Allocated Budget)'
}, {
value: [5000, 14000, 28000, 31000, 42000, 21000],
name: '实际开销(Actual Spending)'
}]
}]
};
Legend
legend: {
data: [...],
orient: 'vertical',
left: '400px',
bottom: '450',
icon: 'circle',
},
radar
radar: {
name: {
textStyle: {..., fontSize: 14, fontWeight: 700}
},
nameGap: 16,
center: ['70%', '50%'],
radius: 100,
indicator:[...],
splitArea: {
areaStyle: {color: ['none','none', 'none','none', 'none']}
},
axisLine: {
lineStyle: {color: '#cde6f5'},
},
splitLine: {
lineStyle: {color: '#cde6f5'},
}
},
雷达面统一颜色
splitArea: {
show: false
},
雷达线数量
Series
type (图表类型)
data (数据)
data: [{
value: [4300, 10000, 28000, 35000, 50000, 19000],
name: '预算分配(Allocated Budget)'
}, {
value: [5000, 14000, 28000, 31000, 42000, 21000],
name: '实际开销(Actual Spending)'
}],
itemStyle (点)
lineStyle (线)
areaStyle (面)
Demo
series: [
{
...
z: 1,
},
{
type: 'radar',
data: [{
value: [4300, '', '', '', '', ''],
}],
z: 2,
itemStyle: {normal: {color: '#A66CFE'}},
lineStyle: {width: 0,labelLine: {show: false }}
},
{
type: 'radar',
data: [{
value: ['', 10000, '', '', '', ''],
}],
z: 3,
itemStyle: {color: 'red'},
lineStyle: {width: 0,labelLine: {show: false}},
},
{
type: 'radar',
data: [{
symbolSize: 10,
value: ['', '', '', '', '', ''],
}],
z: 999,
itemStyle: {color: 'blcak'},
lineStyle: {width: 0,labelLine: {show: false}}
}
]