Commit cef6d30f by BellCodeEditor

save project

parent e0e6d407
Showing with 13 additions and 13 deletions
from pyecharts.charts import Bar from pyecharts.charts import Bar
subjects = ["语文","数学","英语","地理","历史","政治","生物","化学","物理"] subjects = ["语文","数学","英语","地理","历史","政治","生物","化学","物理"]
scores = [88, 95, 96, 94, 62, 66, 64, 93, 89] scores = [138, 145, 136, 94, 92, 86, 76, 93, 92]
bar = Bar() bar = Bar()
bar.add_xaxis(subjects) bar.add_xaxis(subjects)
bar.add_yaxis("qwerty",scores) bar.add_yaxis("qwerty",scores)
......
...@@ -7,11 +7,11 @@ ...@@ -7,11 +7,11 @@
</head> </head>
<body> <body>
<div id="447d1676d9d749b2afe937156e303fd7" class="chart-container" style="width:900px; height:500px;"></div> <div id="85aeca4a99694d74bd95ece577cd718f" class="chart-container" style="width:900px; height:500px;"></div>
<script> <script>
var chart_447d1676d9d749b2afe937156e303fd7 = echarts.init( var chart_85aeca4a99694d74bd95ece577cd718f = echarts.init(
document.getElementById('447d1676d9d749b2afe937156e303fd7'), 'white', {renderer: 'canvas'}); document.getElementById('85aeca4a99694d74bd95ece577cd718f'), 'white', {renderer: 'canvas'});
var option_447d1676d9d749b2afe937156e303fd7 = { var option_85aeca4a99694d74bd95ece577cd718f = {
"animation": true, "animation": true,
"animationThreshold": 2000, "animationThreshold": 2000,
"animationDuration": 1000, "animationDuration": 1000,
...@@ -52,15 +52,15 @@ ...@@ -52,15 +52,15 @@
"name": "qwerty", "name": "qwerty",
"legendHoverLink": true, "legendHoverLink": true,
"data": [ "data": [
88, 138,
95, 145,
96, 136,
94, 94,
62, 92,
66, 86,
64, 76,
93, 93,
89 92
], ],
"showBackground": false, "showBackground": false,
"barMinHeight": 0, "barMinHeight": 0,
...@@ -165,7 +165,7 @@ ...@@ -165,7 +165,7 @@
} }
] ]
}; };
chart_447d1676d9d749b2afe937156e303fd7.setOption(option_447d1676d9d749b2afe937156e303fd7); chart_85aeca4a99694d74bd95ece577cd718f.setOption(option_85aeca4a99694d74bd95ece577cd718f);
</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