Toggle navigation
单条非实时数据的显示demo
By
最***弱
2018-11-14 03:20:52
脚本
16
21
作品使用的第三方脚本
数据管理
上传数据
支持小于 5M 任意格式(csv, xlsx, json, xml, ...)的数据文件
上传后可以通过生成的文件链接异步获取托管的数据。
历史数据
0 条
无历史数据
代码修改记录
信息提示
保存作品
对当前截图不满意?你还可以
上传本地截图
重新截图
作品名称
作品描述
标签
geo
grid
legend
markLine
markPoint
bar
effectScatter
line
lines
map
timeline
title
toolbox
tooltip
visualMap
作品默认版本
最新
16
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
20:11:45
图表已生成
整理代码
刷新
代码
option = { title: { text: '2018-11-12温度走势' //,subtext: 'From ExcelHome' //,sublink: 'http://e.weibo.com/1341556070/AjQH99che' }, legend: { data:['温度','湿度'] }, toolbox:{ show:true, feature:{ saveAsImage:{ show:true } } }, tooltip : { trigger: 'axis', axisPointer : { // 坐标轴指示器,坐标轴触发有效 type : 'shadow' // 默认为直线,可选为:'line' | 'shadow' }, formatter: function (params) { //debugger var len=params.length; var showHtml=params[0].name+"
"; for(var i=0;i
1){ showHtml+=('最高温度: ' +(tar.value[1]+tar.value[3]) + '
'); showHtml+=('平均温度: ' +tar.value[2] + '
'); }else{ showHtml+=('最低温度' + ' : ' + tar.value+ '
'); } } return showHtml; } }, grid: { left: '3%', right: '4%', bottom: '3%', containLabel: true }, xAxis: { type : 'category', splitLine: {show:false}, data : ['14:00:12\n','14:01:12','14:02:12','14:03:12','14:04:12'] }, yAxis: { type : 'value' }, series: [ { name: '设备1最低温度', type: 'bar', stack: '设备1data', cursor:'auto', barWidth:2, itemStyle: { normal: { barBorderColor: 'rgba(0,0,0,0)', color: 'rgba(0,0,0,0)' }, emphasis: { barBorderColor: 'rgba(0,0,0,0)', color: 'rgba(0,0,0,0)' } }, data: [7, 2, 0, 5, 10]//最低温度值 }, { name: '温度', type: 'bar', stack: '设备1data', data:[[0,1,8,7], [1,8,7,2], [2,7,7,0], [3,6,6,5], [4,0.1,6,10]]//最高温度=最高温度-最低温度 }, { name:'设备1最高温度标线', type:'line', //yAxisIndex: 1, itemStyle:{normal:{color:'#c23531'}}, data:[8, 10,7,11,10], markPoint : { color:'blue', data : [ {type : 'max', name : '最大值'}/*, {type : 'min', name : '最小值'}*/ ] } } ] };