目标想达到如下图的效果:
但是实际编码时却是下图的效果:
下面是我的源码:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>仪表盘</title>
<script src="../JS/echarts.js"></script>
</head>
<body>
<div style="width: 600px;height: 400px"></div>
<script>
var mCharts = echarts.init(document.querySelector("div"))
var option = {
series:[
{
type:'gauge',
data:[
{
value:97,
itemStyle:{
color:'pink',
}
},
{
value:85,
itemStyle:{
color:'green'
}
}
],
min:50
}
]
}
mCharts.setOption(option)
</script>
</body>
</html>
想问问应该要如何修改呢?