Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Administrator
/
level3-lesson24-diy2
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
14103492
authored
May 28, 2022
by
BellCodeEditor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
save project
parent
0bdd1a77
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
61 additions
and
23 deletions
analysis.html
q.py
analysis.html
View file @
14103492
...
...
@@ -7,11 +7,11 @@
</head>
<body>
<div
id=
"
82084d75f8074556822923249db36a3
f"
class=
"chart-container"
style=
"width:900px; height:500px;"
></div>
<div
id=
"
39b63a45dba24dcf875cfb837b10e6f
f"
class=
"chart-container"
style=
"width:900px; height:500px;"
></div>
<script>
var
chart_
82084d75f8074556822923249db36a3
f
=
echarts
.
init
(
document
.
getElementById
(
'
82084d75f8074556822923249db36a3
f'
),
'white'
,
{
renderer
:
'canvas'
});
var
option_
82084d75f8074556822923249db36a3
f
=
{
var
chart_
39b63a45dba24dcf875cfb837b10e6f
f
=
echarts
.
init
(
document
.
getElementById
(
'
39b63a45dba24dcf875cfb837b10e6f
f'
),
'white'
,
{
renderer
:
'canvas'
});
var
option_
39b63a45dba24dcf875cfb837b10e6f
f
=
{
"animation"
:
true
,
"animationThreshold"
:
2000
,
"animationDuration"
:
1000
,
...
...
@@ -49,13 +49,12 @@
"series"
:
[
{
"type"
:
"bar"
,
"name"
:
"\u
671f\u4e2d
"
,
"name"
:
"\u
7b2c\u4e00\u5929
"
,
"legendHoverLink"
:
true
,
"data"
:
[
92
,
95
,
82
,
88
5453
,
7548
,
6543
],
"showBackground"
:
false
,
"barWidth"
:
40
,
...
...
@@ -77,13 +76,39 @@
},
{
"type"
:
"bar"
,
"name"
:
"\u
671f\u672b
"
,
"name"
:
"\u
7b2c\u4e8c\u5929
"
,
"legendHoverLink"
:
true
,
"data"
:
[
95
,
79
,
93
,
90
1840
,
4013
,
3421
],
"showBackground"
:
false
,
"barWidth"
:
40
,
"barMinHeight"
:
0
,
"barCategoryGap"
:
"20%"
,
"barGap"
:
"30%"
,
"large"
:
false
,
"largeThreshold"
:
400
,
"seriesLayoutBy"
:
"column"
,
"datasetIndex"
:
0
,
"clip"
:
true
,
"zlevel"
:
0
,
"z"
:
2
,
"label"
:
{
"show"
:
true
,
"position"
:
"top"
,
"margin"
:
8
}
},
{
"type"
:
"bar"
,
"name"
:
"\u7b2c\u4e09\u5929"
,
"legendHoverLink"
:
true
,
"data"
:
[
1080
,
1673
,
2342
],
"showBackground"
:
false
,
"barWidth"
:
40
,
...
...
@@ -107,12 +132,14 @@
"legend"
:
[
{
"data"
:
[
"\u671f\u4e2d"
,
"\u671f\u672b"
"\u7b2c\u4e00\u5929"
,
"\u7b2c\u4e8c\u5929"
,
"\u7b2c\u4e09\u5929"
],
"selected"
:
{
"\u671f\u4e2d"
:
true
,
"\u671f\u672b"
:
true
"\u7b2c\u4e00\u5929"
:
true
,
"\u7b2c\u4e8c\u5929"
:
true
,
"\u7b2c\u4e09\u5929"
:
true
}
}
],
...
...
@@ -155,10 +182,9 @@
}
},
"data"
:
[
"\u6d48\u6d48"
,
"\u806a\u806a"
,
"\u5c0f\u667a"
,
"\u6ce2\u5947"
"\u5343\u4e0e\u5343\u5bfb"
,
"\u73a9\u5177\u603b\u52a8\u5458 4"
,
"\u2fca\u2f90\u2f08\uff1a\u5168\u7403\u8ffd\u7f09"
]
}
],
...
...
@@ -186,7 +212,7 @@
}
]
};
chart_
82084d75f8074556822923249db36a3f
.
setOption
(
option_82084d75f8074556822923249db36a3
f
);
chart_
39b63a45dba24dcf875cfb837b10e6ff
.
setOption
(
option_39b63a45dba24dcf875cfb837b10e6f
f
);
</script>
</body>
</html>
q.py
0 → 100644
View file @
14103492
from
pyecharts.charts
import
Bar
names
=
[
'千与千寻'
,
'玩具总动员 4'
,
'⿊⾐⼈:全球追缉'
]
day1
=
[
5453
,
7548
,
6543
]
day2
=
[
1840
,
4013
,
3421
]
day3
=
[
1080
,
1673
,
2342
]
bar
=
Bar
()
bar
.
add_xaxis
(
names
)
bar
.
add_yaxis
(
"第一天"
,
day1
,
bar_width
=
40
)
bar
.
add_yaxis
(
"第二天"
,
day2
,
bar_width
=
40
)
bar
.
add_yaxis
(
"第三天"
,
day3
,
bar_width
=
40
)
bar
.
render
(
"analysis.html"
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment