效果图:
setLeiDaChart(){
let myChart = this.$echarts.init(document.getElementById('andonType'));
let option = {
radar: [{
// 雷达维度
indicator: [{
text: '运输单位'
},
{
text: '销售单位'
},
{
text: '使用单位'
},
{
text: '生产单位'
},
{
text: '处置单位'
},
{
text: '储存单位'
}
],
center: ['50%', '50%'], // 位置
radius: 100, //大小
startAngle: 90,
splitNumber: 4,
shape: 'rect', // 雷达样式图
name: {
formatter: '{value}',
textStyle: {
fontSize:16,
color: '#B8CBF7' // 文字颜色
}
},
splitArea: {
areaStyle: {
color: [], //圆环颜色
shadowColor: 'rgba(31,37,82,1)', // 圆颜色
shadowBlur: 10
}
},
axisLine: { // 坐标轴线
lineStyle: {
width : 1,
color: '#1F2552'// // 图表背景网格线的颜色
}
},
splitLine: { // // 网格线
lineStyle: {
width : 1,
color: '#1F2552'
}
}
}],
series: [{
name: '雷达图',
type: 'radar',
itemStyle: {
emphasis: {
color: '#2FC25B',
lineStyle: {
width: 4
}
}
},
data: [{
value: [5678, 3678, -6781, 1678, 1780, 3671],
areaStyle: {
normal: {
color: '#0F5CB0' // 选择区域颜色
}
},
lineStyle: {
color: '#2FC25B', // 雷达构成的区域边框
}
}]
}]
}
// 为echarts对象加载数据
myChart.setOption(option);
}