Commit 83e289c5 by BellCodeEditor

save project

parent aefdd0f8
Showing with 18 additions and 15 deletions
......@@ -7,11 +7,11 @@
</head>
<body>
<div id="23af9850c270401988ed035f2883b891" class="chart-container" style="width:900px; height:500px;"></div>
<div id="141941ff109d4b4db0300509a1713bd2" class="chart-container" style="width:900px; height:500px;"></div>
<script>
var chart_23af9850c270401988ed035f2883b891 = echarts.init(
document.getElementById('23af9850c270401988ed035f2883b891'), 'white', {renderer: 'canvas'});
var option_23af9850c270401988ed035f2883b891 = {
var chart_141941ff109d4b4db0300509a1713bd2 = echarts.init(
document.getElementById('141941ff109d4b4db0300509a1713bd2'), 'white', {renderer: 'canvas'});
var option_141941ff109d4b4db0300509a1713bd2 = {
"animation": true,
"animationThreshold": 2000,
"animationDuration": 1000,
......@@ -186,7 +186,7 @@
}
]
};
chart_23af9850c270401988ed035f2883b891.setOption(option_23af9850c270401988ed035f2883b891);
chart_141941ff109d4b4db0300509a1713bd2.setOption(option_141941ff109d4b4db0300509a1713bd2);
</script>
</body>
</html>
from pyecharts.charts import Bar
from pyecharts.charts import Line
subjects = ["浈浈", "聪聪", "小智", "波奇"]
scores1 = [92, 95, 82, 88] # 期中成绩
scores2 = [95, 79, 93, 90] # 期末成绩
bar=Bar()
bar.add_xaxis(subjects)
bar.add_yaxis("期中成绩",scores1,bar_width=40)
bar.add_yaxis("期末成绩",scores2,bar_width=40)
bar.render('asd.html')
\ No newline at end of file
text = ["1","2","3","4","5","6","7","8","9","10"]
student1 = [112,110,118,124,132,136,144,143]
student2 = [128,131,132,129,130,127,129,123]
student3 = [145,134,121,133,154,131,132,134]
Line=Line()
line.add_xaxis(test)
line.add_yaxis("聪聪",student1)
line.add_yaxis("小杰",student2)
line.add_yaxis("皮皮",student3)
line.set_jlobal_opts(title_opts={"text":"成绩走势图","stutext":"高524班数学"})
line.render("a.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