const EducationStaticsRedar = (echarts: any) => { // 实例化对象 const myChart = echarts.init(document.getElementById("educationStatics")); // 配置项 const option = { tooltip: { show: true }, radar: { // shape: 'circle', // , axisLabel: { show: true } indicator: [ { name: "大专以下", max: 800 }, { name: "博士及以上", max: 800 }, { name: "硕士", max: 800 }, { name: "本科", max: 800 }, { name: "大专", max: 800 } ], splitArea: { show: false }, axisLine: { show: false } }, series: [ { name: "学历统计", type: "radar", data: [ { value: [100, 210, 400, 720, 230], name: "学历统计" } ], label: { show: false, formatter: function (params: any) { return params.value; } }, itemStyle: { //此属性的颜色和下面areaStyle属性的颜色都设置成相同色即可实现 color: "#4D95E9", borderColor: "#4D95E9" }, areaStyle: { color: "rgba(77,149,233,0.26)" } } ] }; // 配置项给实例对象 myChart.setOption(option); return myChart; }; export default EducationStaticsRedar;