option = {
xAxis: {
type: 'category',
data: ['10', '20', '30', '40', '50', '60', '70']
},
yAxis: {
type: 'value'
},
series: [{
data: [820, 932, 901, 934, 1290, 1330, 1320],
type: 'line',
itemStyle: {
color: "orange",
},
markLine: {
data: [
[
{ name: '标线1起点', xAxis: '10', yAxis: 300},
{ name: '标线1终点', xAxis: '30', yAxis: 300},
],
],
label: {
normal: {
show: true,
position: 'middle',
formatter: '警戒线',
},
},
lineStyle: {
normal: {
type: "dashed",
color: 'red',
},
},
},
}]
};
echart设置标线
最新推荐文章于 2024-05-06 15:49:21 发布