You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
274 lines
9.2 KiB
274 lines
9.2 KiB
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<title>Awesome-pyecharts</title>
|
|
<script type="text/javascript" src="https://assets.pyecharts.org/assets/v5/echarts.min.js"></script>
|
|
|
|
|
|
</head>
|
|
<body >
|
|
<div id="30dbf1d9b9bf4c76a79725d385eb5254" class="chart-container" style="width:1200px; height:600px; "></div>
|
|
<script>
|
|
var chart_30dbf1d9b9bf4c76a79725d385eb5254 = echarts.init(
|
|
document.getElementById('30dbf1d9b9bf4c76a79725d385eb5254'), 'white', {renderer: 'canvas'});
|
|
var option_30dbf1d9b9bf4c76a79725d385eb5254 = {
|
|
"animation": true,
|
|
"animationThreshold": 2000,
|
|
"animationDuration": 1000,
|
|
"animationEasing": "cubicOut",
|
|
"animationDelay": 0,
|
|
"animationDurationUpdate": 300,
|
|
"animationEasingUpdate": "cubicOut",
|
|
"animationDelayUpdate": 0,
|
|
"aria": {
|
|
"enabled": false
|
|
},
|
|
"color": [
|
|
"#5470c6",
|
|
"#91cc75",
|
|
"#fac858",
|
|
"#ee6666",
|
|
"#73c0de",
|
|
"#3ba272",
|
|
"#fc8452",
|
|
"#9a60b4",
|
|
"#ea7ccc"
|
|
],
|
|
"series": [
|
|
{
|
|
"type": "bar",
|
|
"name": "\u4e0a\u4f20\u6570\u91cf",
|
|
"legendHoverLink": true,
|
|
"data": [
|
|
323,
|
|
302,
|
|
279,
|
|
276,
|
|
241,
|
|
239,
|
|
183,
|
|
143,
|
|
136,
|
|
134
|
|
],
|
|
"realtimeSort": false,
|
|
"showBackground": false,
|
|
"stackStrategy": "samesign",
|
|
"cursor": "pointer",
|
|
"barMinHeight": 0,
|
|
"barCategoryGap": "20%",
|
|
"barGap": "30%",
|
|
"large": false,
|
|
"largeThreshold": 400,
|
|
"seriesLayoutBy": "column",
|
|
"datasetIndex": 0,
|
|
"clip": true,
|
|
"zlevel": 0,
|
|
"z": 2,
|
|
"label": {
|
|
"show": true,
|
|
"position": "right",
|
|
"margin": 8,
|
|
"formatter": function(params){ return params.value + ' (' + params.name.split('').join('\n') + ')';},
|
|
"valueAnimation": false
|
|
},
|
|
"itemStyle": {
|
|
"color": function(params){ return ['rgb(75, 115, 220)', 'rgb(90, 105, 200)', 'rgb(105, 95, 180)', 'rgb(120, 85, 160)', 'rgb(135, 75, 140)', 'rgb(150, 65, 120)', 'rgb(165, 55, 100)', 'rgb(180, 45, 80)', 'rgb(195, 35, 60)', 'rgb(210, 25, 40)'][params.dataIndex];}
|
|
}
|
|
}
|
|
],
|
|
"legend": [
|
|
{
|
|
"data": [
|
|
"\u4e0a\u4f20\u6570\u91cf"
|
|
],
|
|
"selected": {},
|
|
"show": true,
|
|
"padding": 5,
|
|
"itemGap": 10,
|
|
"itemWidth": 25,
|
|
"itemHeight": 14,
|
|
"backgroundColor": "transparent",
|
|
"borderColor": "#ccc",
|
|
"borderRadius": 0,
|
|
"pageButtonItemGap": 5,
|
|
"pageButtonPosition": "end",
|
|
"pageFormatter": "{current}/{total}",
|
|
"pageIconColor": "#2f4554",
|
|
"pageIconInactiveColor": "#aaa",
|
|
"pageIconSize": 15,
|
|
"animationDurationUpdate": 800,
|
|
"selector": false,
|
|
"selectorPosition": "auto",
|
|
"selectorItemGap": 7,
|
|
"selectorButtonGap": 10
|
|
}
|
|
],
|
|
"tooltip": {
|
|
"show": true,
|
|
"trigger": "item",
|
|
"triggerOn": "mousemove|click",
|
|
"axisPointer": {
|
|
"type": "line"
|
|
},
|
|
"showContent": true,
|
|
"alwaysShowContent": false,
|
|
"showDelay": 0,
|
|
"hideDelay": 100,
|
|
"enterable": false,
|
|
"confine": false,
|
|
"appendToBody": false,
|
|
"transitionDuration": 0.4,
|
|
"formatter": function(params){ return params.name + '<br/>' + '\u6240\u5c5e\u884c\u653f\u533a\uff1a' + ['\u7701\u5c5e\u4ee3\u7ba1', '\u7701\u5c5e\u4ee3\u7ba1', '\u4e8c\u9053\u533a', '\u7701\u5c5e\u4ee3\u7ba1', '\u76f4\u5c5e\u4ee3\u7ba1', '\u76f4\u5c5e\u4ee3\u7ba1', '\u76f4\u5c5e\u4ee3\u7ba1', '\u76f4\u5c5e\u4ee3\u7ba1', '\u76f4\u5c5e\u4ee3\u7ba1', '\u65b0\u533a\u4ee3\u7ba1'][params.dataIndex] + '<br/>' + '\u4e0a\u4f20\u6570\u91cf\uff1a<b style=\"color:#5470C6\">' + params.value + '</b>' },
|
|
"textStyle": {
|
|
"fontSize": 14
|
|
},
|
|
"borderWidth": 0,
|
|
"padding": 5,
|
|
"order": "seriesAsc"
|
|
},
|
|
"xAxis": [
|
|
{
|
|
"show": true,
|
|
"scale": false,
|
|
"nameLocation": "end",
|
|
"nameGap": 15,
|
|
"gridIndex": 0,
|
|
"axisLabel": {
|
|
"show": true,
|
|
"rotate": 30,
|
|
"margin": 8,
|
|
"formatter": function(value){ return value.length > 6 ? value.substring(0,6)+'...' : value;},
|
|
"valueAnimation": false
|
|
},
|
|
"inverse": false,
|
|
"offset": 0,
|
|
"splitNumber": 5,
|
|
"minInterval": 0,
|
|
"splitLine": {
|
|
"show": true,
|
|
"lineStyle": {
|
|
"show": true,
|
|
"width": 1,
|
|
"opacity": 1,
|
|
"curveness": 0,
|
|
"type": "solid"
|
|
}
|
|
},
|
|
"animation": true,
|
|
"animationThreshold": 2000,
|
|
"animationDuration": 1000,
|
|
"animationEasing": "cubicOut",
|
|
"animationDelay": 0,
|
|
"animationDurationUpdate": 300,
|
|
"animationEasingUpdate": "cubicOut",
|
|
"animationDelayUpdate": 0
|
|
}
|
|
],
|
|
"yAxis": [
|
|
{
|
|
"name": "\u4e0a\u4f20\u6570\u91cf\uff08\u4ef6\uff09",
|
|
"show": true,
|
|
"scale": false,
|
|
"nameLocation": "end",
|
|
"nameGap": 15,
|
|
"gridIndex": 0,
|
|
"inverse": false,
|
|
"offset": 0,
|
|
"splitNumber": 5,
|
|
"minInterval": 0,
|
|
"splitLine": {
|
|
"show": true,
|
|
"lineStyle": {
|
|
"show": true,
|
|
"width": 1,
|
|
"opacity": 1,
|
|
"curveness": 0,
|
|
"type": "solid"
|
|
}
|
|
},
|
|
"animation": true,
|
|
"animationThreshold": 2000,
|
|
"animationDuration": 1000,
|
|
"animationEasing": "cubicOut",
|
|
"animationDelay": 0,
|
|
"animationDurationUpdate": 300,
|
|
"animationEasingUpdate": "cubicOut",
|
|
"animationDelayUpdate": 0,
|
|
"data": [
|
|
"\u4e1c\u5317\u5e08\u8303\u5927\u5b66\u9644\u5c5e\u4e2d\u5b66",
|
|
"\u5409\u6797\u7701\u5b9e\u9a8c\u4e2d\u5b66",
|
|
"\u957f\u6625\u4e94\u5341\u4e8c\u4e2d\u8d6b\u884c\u5b9e\u9a8c\u5b66\u6821",
|
|
"\u4e1c\u5317\u5e08\u8303\u5927\u5b66\u9644\u5c5e\u5b9e\u9a8c\u5b66\u6821",
|
|
"\u957f\u6625\u5e02\u7b2c\u4e8c\u5b9e\u9a8c\u4e2d\u5b66",
|
|
"\u957f\u6625\u5e02\u5341\u4e00\u9ad8\u4e2d",
|
|
"\u957f\u6625\u5e02\u5b9e\u9a8c\u4e2d\u5b66",
|
|
"\u957f\u6625\u5e02\u7b2c\u4e00\u5b9e\u9a8c\u94f6\u6cb3\u5c0f\u5b66",
|
|
"\u957f\u6625\u5e02\u7b2c\u4e8c\u4e2d\u5b66",
|
|
"\u5409\u6797\u7701\u7b2c\u4e8c\u5b9e\u9a8c\u9ad8\u65b0\u5b66\u6821"
|
|
]
|
|
}
|
|
],
|
|
"title": [
|
|
{
|
|
"show": true,
|
|
"text": "\u4e0a\u4f20\u8d44\u6e90\u6570\u91cfTOP10\u5b66\u6821\u6392\u540d",
|
|
"target": "blank",
|
|
"subtext": "\u6570\u636e\u6765\u6e90\uff1a\u8bfe\u7a0b\u8d44\u6e90\u7ba1\u7406\u7cfb\u7edf",
|
|
"subtarget": "blank",
|
|
"padding": 5,
|
|
"itemGap": 10,
|
|
"textAlign": "auto",
|
|
"textVerticalAlign": "auto",
|
|
"triggerEvent": false
|
|
}
|
|
],
|
|
"visualMap": {
|
|
"show": true,
|
|
"type": "continuous",
|
|
"min": 134,
|
|
"max": 323,
|
|
"inRange": {
|
|
"color": [
|
|
"#91CC75",
|
|
"#5470C6"
|
|
]
|
|
},
|
|
"calculable": true,
|
|
"inverse": false,
|
|
"splitNumber": 5,
|
|
"hoverLink": true,
|
|
"orient": "horizontal",
|
|
"left": "center",
|
|
"padding": 5,
|
|
"showLabel": true,
|
|
"itemWidth": 20,
|
|
"itemHeight": 140,
|
|
"borderWidth": 0
|
|
},
|
|
"dataZoom": [
|
|
{
|
|
"show": true,
|
|
"type": "inside",
|
|
"showDetail": true,
|
|
"showDataShadow": true,
|
|
"realtime": true,
|
|
"start": 20,
|
|
"end": 80,
|
|
"orient": "horizontal",
|
|
"zoomLock": false,
|
|
"filterMode": "filter",
|
|
"disabled": false,
|
|
"zoomOnMouseWheel": true,
|
|
"moveOnMouseMove": true,
|
|
"moveOnMouseWheel": true,
|
|
"preventDefaultMouseMove": true
|
|
}
|
|
]
|
|
};
|
|
chart_30dbf1d9b9bf4c76a79725d385eb5254.setOption(option_30dbf1d9b9bf4c76a79725d385eb5254);
|
|
</script>
|
|
</body>
|
|
</html>
|