Commit 2902c9a3 by BellCodeEditor

save project

parent 637b6daf
Showing with 14 additions and 12 deletions
...@@ -7,11 +7,11 @@ ...@@ -7,11 +7,11 @@
</head> </head>
<body> <body>
<div id="2f2a760f4ae74cddaedc79dc8b0590f9" class="chart-container" style="width:900px; height:500px;"></div> <div id="8e74337d4a054ec5b5e29de1b2e541da" class="chart-container" style="width:900px; height:500px;"></div>
<script> <script>
var chart_2f2a760f4ae74cddaedc79dc8b0590f9 = echarts.init( var chart_8e74337d4a054ec5b5e29de1b2e541da = echarts.init(
document.getElementById('2f2a760f4ae74cddaedc79dc8b0590f9'), 'white', {renderer: 'canvas'}); document.getElementById('8e74337d4a054ec5b5e29de1b2e541da'), 'white', {renderer: 'canvas'});
var option_2f2a760f4ae74cddaedc79dc8b0590f9 = { var option_8e74337d4a054ec5b5e29de1b2e541da = {
"animation": true, "animation": true,
"animationThreshold": 2000, "animationThreshold": 2000,
"animationDuration": 1000, "animationDuration": 1000,
...@@ -201,7 +201,7 @@ ...@@ -201,7 +201,7 @@
} }
] ]
}; };
chart_2f2a760f4ae74cddaedc79dc8b0590f9.setOption(option_2f2a760f4ae74cddaedc79dc8b0590f9); chart_8e74337d4a054ec5b5e29de1b2e541da.setOption(option_8e74337d4a054ec5b5e29de1b2e541da);
</script> </script>
</body> </body>
</html> </html>
from pyecharts.charts import Bar from pyecharts.charts import Line
subjects = ["语文","数学","英语","地理","历史","政治","生物","化学","物理"] subjects = ["语文","数学","英语","地理","历史","政治","生物","化学","物理"]
scores1 = [88, 95, 96, 94, 62, 66, 64, 93, 89] scores1 = [88, 95, 96, 94, 62, 66, 64, 93, 89]
scores2 = [88, 95, 96, 94, 62, 66, 64, 93, 89] scores2 = [88, 95, 96, 94, 62, 66, 64, 93, 89]
bar=Bar() scores3 = [88, 95, 96, 94, 62, 66, 64, 93, 89]
bar.add_xaxis(subjects) line=Line()
bar.add_yaxis("期中",scores1,bar_width=40) line.add_xaxis()
bar.add_yaxis("期末",scores2,bar_width=40) line.add_yaxis("聪聪",scores1)
bar.render("666.html") line.add_yaxis("小杰",scores2)
\ No newline at end of file line.add_yaxis("皮皮",scores3)
line.render("888.html")
\ No newline at end of file
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