当前位置:网站首页>Common effects of line chart
Common effects of line chart
2022-07-08 01:11:00 【Just love life】
Common effect
Mark : Maximum minimum value Average Mark the interval
markPoint 、markLine、markArea

Code
<!-- 1.ECharts The most basic code structure 2.x Axis data :['1 month ','2 month ','3 month ','4 month ','5 month ','6 month ','7 month ','8 month ','9 month ','10 month ','11 month ','12 month '] 3.y Axis data :[3000,2800,900,1000,800,700,1400,1300,900,1000,800,600] 4. take type Is set to bar --> <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Document</title> <script src="lib/echarts.min.js"></script> </head> <body> <div style="width: 600px;height: 400px;"></div> <script> var mCharts= echarts.init(document.querySelector('div')) var xDataArr=['1 month ','2 month ','3 month ','4 month ','5 month ','6 month ','7 month ','8 month ','9 month ','10 month ','11 month ','12 month '] var yDaraArr=[3000,2800,900,1000,800,700,1400,1300,900,1000,800,600] var option={
xAxis:{
type:'category' ,// Taxonomic axis
data:xDataArr
}, yAxis:{
type:'value' ,// Value axis
}, series:[
{
name:' a brand of instant noodles ', type:'line', //bar It's a histogram ,line It's linear ,pie It's pie shaped data:yDaraArr, markPoint:{
data:[
{
type:'max'
},
{
type:'min'
}
]
}, markLine:{
data:[
{
type:'average'
}
]
}, markArea:{
data:[ [
{
xAxis:'1 month '
},
{
xAxis:'2 month '
}
],[
{
xAxis:'7 month '
},{
xAxis:'8 month '
}
]
]
}
}
]
}
// step 5: Set the configuration item to echarts Instance object
mCharts.setOption(option)
</script>
</body>
</html>
Line control : smooth 、 style
smooth、lineStyle
Fill the style
areaStyle
Code
<!-- 1.ECharts The most basic code structure 2.x Axis data :['1 month ','2 month ','3 month ','4 month ','5 month ','6 month ','7 month ','8 month ','9 month ','10 month ','11 month ','12 month '] 3.y Axis data :[3000,2800,900,1000,800,700,1400,1300,900,1000,800,600] 4. take type Is set to bar --> <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Document</title> <script src="lib/echarts.min.js"></script> </head> <body> <div style="width: 600px;height: 400px;"></div> <script> var mCharts= echarts.init(document.querySelector('div')) var xDataArr=['1 month ','2 month ','3 month ','4 month ','5 month ','6 month ','7 month ','8 month ','9 month ','10 month ','11 month ','12 month '] var yDaraArr=[3000,2800,900,1000,800,700,1400,1300,900,1000,800,600] var option={
xAxis:{
type:'category' ,// Taxonomic axis
data:xDataArr
}, yAxis:{
type:'value' ,// Value axis
}, series:[
{
name:' a brand of instant noodles ', type:'line', //bar It's a histogram ,line It's linear ,pie It's pie shaped data:yDaraArr, markPoint:{
data:[
{
type:'max'
},
{
type:'min'
}
]
}, markLine:{
data:[
{
type:'average'
}
]
}, markArea:{
data:[ [
{
xAxis:'1 month '
},
{
xAxis:'2 month '
}
],[
{
xAxis:'7 month '
},{
xAxis:'8 month '
}
]
]
}, smooth:true , // smooth lineStyle:{
color:'blue',
type:'solid' //dashed dotted solid
}, areaStyle:{
color:'pink'
}
}
]
}
// step 5: Set the configuration item to echarts Instance object
mCharts.setOption(option)
</script>
</body>
</html>
边栏推荐
- Marubeni official website applet configuration tutorial is coming (with detailed steps)
- 基于卷积神经网络的恶意软件检测方法
- How does starfish OS enable the value of SFO in the fourth phase of SFO destruction?
- My best game based on wechat applet development
- Study notes of single chip microcomputer and embedded system
- Chapter 5 neural network
- SDNU_ ACM_ ICPC_ 2022_ Summer_ Practice(1~2)
- Hotel
- AI zhetianchuan ml novice decision tree
- Su embedded training - Day6
猜你喜欢

5. Over fitting, dropout, regularization

My best game based on wechat applet development

HDMI to VGA acquisition HD adapter scheme | HDMI to VGA 1080p audio and video converter scheme | cs5210 scheme design explanation

From starfish OS' continued deflationary consumption of SFO, the value of SFO in the long run

Cancel the down arrow of the default style of select and set the default word of select

Interface test advanced interface script use - apipost (pre / post execution script)

Design method and reference circuit of type C to hdmi+ PD + BB + usb3.1 hub (rj45/cf/tf/ sd/ multi port usb3.1 type-A) multifunctional expansion dock
![[note] common combined filter circuit](/img/2f/a8c2ef0d76dd7a45b50a64a928a9c8.png)
[note] common combined filter circuit

Malware detection method based on convolutional neural network

SDNU_ ACM_ ICPC_ 2022_ Summer_ Practice(1~2)
随机推荐
Ag7120 and ag7220 explain the driving scheme of HDMI signal extension amplifier | ag7120 and ag7220 design HDMI signal extension amplifier circuit reference
swift获取url参数
Analysis of 8 classic C language pointer written test questions
50MHz generation time
Using GPU to train network model
Capstone/cs5210 chip | cs5210 design scheme | cs5210 design data
Image data preprocessing
12. RNN is applied to handwritten digit recognition
Mathematical modeling -- knowledge map
Fundamentals - integrating third-party technology
My best game based on wechat applet development
Cs5261type-c to HDMI alternative ag9310 | ag9310 alternative
串口接收一包数据
133. Clone map
13. Enregistrement et chargement des modèles
Share a latex online editor | with latex common templates
Password recovery vulnerability of foreign public testing
国内首次,3位清华姚班本科生斩获STOC最佳学生论文奖
英雄联盟胜负预测--简易肯德基上校
股票开户免费办理佣金最低的券商,手机上开户安全吗