Commit 5a37b0a1 by BellCodeEditor

auto save

parent a759c86e
Showing with 71 additions and 60 deletions
from pyecharts.charts import Line
x=['q','w','e','r','t','y','u']
y=[1,21,3,5,4,7,8]
line=Line()
line.add_xaxis(x)
line.add_yaxis('f',y)
line.render()
\ No newline at end of file
...@@ -7,11 +7,11 @@ ...@@ -7,11 +7,11 @@
</head> </head>
<body> <body>
<div id="bdda1f6764494dac95e6b95dde8e31b9" class="chart-container" style="width:900px; height:500px;"></div> <div id="ac4a59a5436c496cae0bd3a068a9cb0c" class="chart-container" style="width:900px; height:500px;"></div>
<script> <script>
var chart_bdda1f6764494dac95e6b95dde8e31b9 = echarts.init( var chart_ac4a59a5436c496cae0bd3a068a9cb0c = echarts.init(
document.getElementById('bdda1f6764494dac95e6b95dde8e31b9'), 'white', {renderer: 'canvas'}); document.getElementById('ac4a59a5436c496cae0bd3a068a9cb0c'), 'white', {renderer: 'canvas'});
var option_bdda1f6764494dac95e6b95dde8e31b9 = { var option_ac4a59a5436c496cae0bd3a068a9cb0c = {
"animation": true, "animation": true,
"animationThreshold": 2000, "animationThreshold": 2000,
"animationDuration": 1000, "animationDuration": 1000,
...@@ -48,71 +48,71 @@ ...@@ -48,71 +48,71 @@
], ],
"series": [ "series": [
{ {
"type": "bar", "type": "line",
"name": "\u6210\u7ee9", "name": "f",
"legendHoverLink": true, "connectNulls": false,
"data": [ "symbolSize": 4,
92, "showSymbol": true,
95, "smooth": false,
82,
88
],
"showBackground": false,
"barWidth": 40,
"barMinHeight": 0,
"barCategoryGap": "20%",
"barGap": "30%",
"large": false,
"largeThreshold": 400,
"seriesLayoutBy": "column",
"datasetIndex": 0,
"clip": true, "clip": true,
"zlevel": 0, "step": false,
"z": 2,
"label": {
"show": true,
"position": "top",
"margin": 8
}
},
{
"type": "bar",
"name": "\u6210\u7ee92",
"legendHoverLink": true,
"data": [ "data": [
95, [
79, "q",
93, 1
90 ],
[
"w",
21
],
[
"e",
3
],
[
"r",
5
],
[
"t",
4
],
[
"y",
7
],
[
"u",
8
]
], ],
"showBackground": false, "hoverAnimation": true,
"barWidth": 40,
"barMinHeight": 0,
"barCategoryGap": "20%",
"barGap": "30%",
"large": false,
"largeThreshold": 400,
"seriesLayoutBy": "column",
"datasetIndex": 0,
"clip": true,
"zlevel": 0,
"z": 2,
"label": { "label": {
"show": true, "show": true,
"position": "top", "position": "top",
"margin": 8 "margin": 8
} },
"lineStyle": {
"show": true,
"width": 1,
"opacity": 1,
"curveness": 0,
"type": "solid"
},
"areaStyle": {
"opacity": 0
},
"zlevel": 0,
"z": 0
} }
], ],
"legend": [ "legend": [
{ {
"data": [ "data": [
"\u6210\u7ee9", "f"
"\u6210\u7ee92"
], ],
"selected": { "selected": {
"\u6210\u7ee9": true, "f": true
"\u6210\u7ee92": true
} }
} }
], ],
...@@ -155,10 +155,13 @@ ...@@ -155,10 +155,13 @@
} }
}, },
"data": [ "data": [
"\u6d48\u6d48", "q",
"\u806a\u806a", "w",
"\u5c0f\u667a", "e",
"\u6ce2\u5947" "r",
"t",
"y",
"u"
] ]
} }
], ],
...@@ -186,7 +189,7 @@ ...@@ -186,7 +189,7 @@
} }
] ]
}; };
chart_bdda1f6764494dac95e6b95dde8e31b9.setOption(option_bdda1f6764494dac95e6b95dde8e31b9); chart_ac4a59a5436c496cae0bd3a068a9cb0c.setOption(option_ac4a59a5436c496cae0bd3a068a9cb0c);
</script> </script>
</body> </body>
</html> </html>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment