2 Star 5 Fork 5

朴拙科技/AutoView

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
run.py 70.96 KB
一键复制 编辑 原始数据 按行查看 历史
LiNan1984 提交于 2021-12-26 23:24 . 创建 run.py
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482
from pyecharts.charts import Pie, Bar, Map, WordCloud, Page,Bar3D,Timeline,Grid,Line,Graph,Liquid,Boxplot,Scatter
from pyecharts.globals import SymbolType,ThemeType
import pyecharts.options as opts
import json
from flask import Flask, render_template
import random
from typing import List
from pyecharts.charts import Line
from pyecharts import options as opts
from pyecharts.charts import Bar
from pyecharts.commons.utils import JsCode
from pyecharts.globals import ThemeType
app = Flask(__name__)
data = [
{
"time": "1993年",
"data": [
{"name": "广东", "value": [3469.0, 10.12, "广东"]},
{"name": "江苏", "value": [2998.0, 8.75, "江苏"]},
{"name": "山东", "value": [2770.0, 8.08, "山东"]},
{"name": "辽宁", "value": [2011.0, 5.87, "辽宁"]},
{"name": "浙江", "value": [1926.0, 5.62, "浙江"]},
{"name": "河北", "value": [1691.0, 4.93, "河北"]},
{"name": "河南", "value": [1660.0, 4.84, "河南"]},
{"name": "上海", "value": [1519.0, 4.43, "上海"]},
{"name": "四川", "value": [1486.0, 4.34, "四川"]},
{"name": "湖北", "value": [1326.0, 3.87, "湖北"]},
{"name": "湖南", "value": [1245.0, 3.63, "湖南"]},
{"name": "黑龙江", "value": [1198.0, 3.5, "黑龙江"]},
{"name": "福建", "value": [1114.0, 3.25, "福建"]},
{"name": "安徽", "value": [1037.0, 3.03, "安徽"]},
{"name": "北京", "value": [886.0, 2.59, "北京"]},
{"name": "广西", "value": [872.0, 2.54, "广西"]},
{"name": "云南", "value": [783.0, 2.28, "云南"]},
{"name": "江西", "value": [723.0, 2.11, "江西"]},
{"name": "吉林", "value": [719.0, 2.1, "吉林"]},
{"name": "山西", "value": [680.0, 1.98, "山西"]},
{"name": "陕西", "value": [678.0, 1.98, "陕西"]},
{"name": "重庆", "value": [609.0, 1.78, "重庆"]},
{"name": "天津", "value": [539.0, 1.57, "天津"]},
{"name": "内蒙古", "value": [538.0, 1.57, "内蒙古"]},
{"name": "新疆", "value": [495.0, 1.44, "新疆"]},
{"name": "贵州", "value": [418.0, 1.22, "贵州"]},
{"name": "甘肃", "value": [372.0, 1.09, "甘肃"]},
{"name": "海南", "value": [260.0, 0.76, "海南"]},
{"name": "青海", "value": [110.0, 0.32, "青海"]},
{"name": "宁夏", "value": [104.0, 0.3, "宁夏"]},
{"name": "西藏", "value": [37.0, 0.11, "西藏"]},
],
},
{
"time": "1994年",
"data": [
{"name": "广东", "value": [4619.0, 10.17, "广东"]},
{"name": "江苏", "value": [4057.0, 8.93, "江苏"]},
{"name": "山东", "value": [3845.0, 8.47, "山东"]},
{"name": "浙江", "value": [2689.0, 5.92, "浙江"]},
{"name": "辽宁", "value": [2462.0, 5.42, "辽宁"]},
{"name": "河南", "value": [2217.0, 4.88, "河南"]},
{"name": "河北", "value": [2187.0, 4.81, "河北"]},
{"name": "四川", "value": [2001.0, 4.41, "四川"]},
{"name": "上海", "value": [1991.0, 4.38, "上海"]},
{"name": "湖北", "value": [1701.0, 3.74, "湖北"]},
{"name": "湖南", "value": [1650.0, 3.63, "湖南"]},
{"name": "福建", "value": [1644.0, 3.62, "福建"]},
{"name": "黑龙江", "value": [1605.0, 3.53, "黑龙江"]},
{"name": "安徽", "value": [1320.0, 2.91, "安徽"]},
{"name": "广西", "value": [1198.0, 2.64, "广西"]},
{"name": "北京", "value": [1145.0, 2.52, "北京"]},
{"name": "云南", "value": [984.0, 2.17, "云南"]},
{"name": "江西", "value": [948.0, 2.09, "江西"]},
{"name": "吉林", "value": [938.0, 2.07, "吉林"]},
{"name": "陕西", "value": [839.0, 1.85, "陕西"]},
{"name": "重庆", "value": [834.0, 1.84, "重庆"]},
{"name": "山西", "value": [827.0, 1.82, "山西"]},
{"name": "天津", "value": [733.0, 1.61, "天津"]},
{"name": "内蒙古", "value": [695.0, 1.53, "内蒙古"]},
{"name": "新疆", "value": [662.0, 1.46, "新疆"]},
{"name": "贵州", "value": [524.0, 1.15, "贵州"]},
{"name": "甘肃", "value": [454.0, 1.0, "甘肃"]},
{"name": "海南", "value": [332.0, 0.73, "海南"]},
{"name": "青海", "value": [138.0, 0.3, "青海"]},
{"name": "宁夏", "value": [136.0, 0.3, "宁夏"]},
{"name": "西藏", "value": [46.0, 0.1, "西藏"]},
],
},
{
"time": "1995年",
"data": [
{"name": "广东", "value": [5933.0, 10.29, "广东"]},
{"name": "江苏", "value": [5155.0, 8.94, "江苏"]},
{"name": "山东", "value": [4953.0, 8.59, "山东"]},
{"name": "浙江", "value": [3558.0, 6.17, "浙江"]},
{"name": "河南", "value": [2988.0, 5.18, "河南"]},
{"name": "河北", "value": [2850.0, 4.94, "河北"]},
{"name": "辽宁", "value": [2793.0, 4.85, "辽宁"]},
{"name": "上海", "value": [2499.0, 4.34, "上海"]},
{"name": "四川", "value": [2443.0, 4.24, "四川"]},
{"name": "湖南", "value": [2132.0, 3.7, "湖南"]},
{"name": "湖北", "value": [2109.0, 3.66, "湖北"]},
{"name": "福建", "value": [2095.0, 3.63, "福建"]},
{"name": "黑龙江", "value": [1991.0, 3.45, "黑龙江"]},
{"name": "安徽", "value": [1811.0, 3.14, "安徽"]},
{"name": "北京", "value": [1508.0, 2.62, "北京"]},
{"name": "广西", "value": [1498.0, 2.6, "广西"]},
{"name": "云南", "value": [1222.0, 2.12, "云南"]},
{"name": "江西", "value": [1170.0, 2.03, "江西"]},
{"name": "吉林", "value": [1137.0, 1.97, "吉林"]},
{"name": "重庆", "value": [1123.0, 1.95, "重庆"]},
{"name": "山西", "value": [1076.0, 1.87, "山西"]},
{"name": "陕西", "value": [1037.0, 1.8, "陕西"]},
{"name": "天津", "value": [932.0, 1.62, "天津"]},
{"name": "内蒙古", "value": [857.0, 1.49, "内蒙古"]},
{"name": "新疆", "value": [815.0, 1.41, "新疆"]},
{"name": "贵州", "value": [636.0, 1.1, "贵州"]},
{"name": "甘肃", "value": [558.0, 0.97, "甘肃"]},
{"name": "海南", "value": [363.0, 0.63, "海南"]},
{"name": "宁夏", "value": [175.0, 0.3, "宁夏"]},
{"name": "青海", "value": [168.0, 0.29, "青海"]},
{"name": "西藏", "value": [56.0, 0.1, "西藏"]},
],
},
{
"time": "1996年",
"data": [
{"name": "广东", "value": [6835.0, 10.07, "广东"]},
{"name": "江苏", "value": [6004.0, 8.84, "江苏"]},
{"name": "山东", "value": [5884.0, 8.67, "山东"]},
{"name": "浙江", "value": [4189.0, 6.17, "浙江"]},
{"name": "河南", "value": [3635.0, 5.35, "河南"]},
{"name": "河北", "value": [3453.0, 5.09, "河北"]},
{"name": "辽宁", "value": [3158.0, 4.65, "辽宁"]},
{"name": "上海", "value": [2958.0, 4.36, "上海"]},
{"name": "四川", "value": [2872.0, 4.23, "四川"]},
{"name": "湖南", "value": [2540.0, 3.74, "湖南"]},
{"name": "湖北", "value": [2500.0, 3.68, "湖北"]},
{"name": "福建", "value": [2484.0, 3.66, "福建"]},
{"name": "黑龙江", "value": [2371.0, 3.49, "黑龙江"]},
{"name": "安徽", "value": [2093.0, 3.08, "安徽"]},
{"name": "北京", "value": [1789.0, 2.63, "北京"]},
{"name": "广西", "value": [1698.0, 2.5, "广西"]},
{"name": "云南", "value": [1518.0, 2.24, "云南"]},
{"name": "江西", "value": [1410.0, 2.08, "江西"]},
{"name": "吉林", "value": [1347.0, 1.98, "吉林"]},
{"name": "重庆", "value": [1315.0, 1.94, "重庆"]},
{"name": "山西", "value": [1292.0, 1.9, "山西"]},
{"name": "陕西", "value": [1216.0, 1.79, "陕西"]},
{"name": "天津", "value": [1122.0, 1.65, "天津"]},
{"name": "内蒙古", "value": [1023.0, 1.51, "内蒙古"]},
{"name": "新疆", "value": [901.0, 1.33, "新疆"]},
{"name": "贵州", "value": [723.0, 1.06, "贵州"]},
{"name": "甘肃", "value": [723.0, 1.06, "甘肃"]},
{"name": "海南", "value": [390.0, 0.57, "海南"]},
{"name": "宁夏", "value": [203.0, 0.3, "宁夏"]},
{"name": "青海", "value": [184.0, 0.27, "青海"]},
{"name": "西藏", "value": [65.0, 0.1, "西藏"]},
],
},
{
"time": "1997年",
"data": [
{"name": "广东", "value": [7775.0, 10.16, "广东"]},
{"name": "江苏", "value": [6680.0, 8.73, "江苏"]},
{"name": "山东", "value": [6537.0, 8.55, "山东"]},
{"name": "浙江", "value": [4686.0, 6.13, "浙江"]},
{"name": "河南", "value": [4041.0, 5.28, "河南"]},
{"name": "河北", "value": [3954.0, 5.17, "河北"]},
{"name": "辽宁", "value": [3582.0, 4.68, "辽宁"]},
{"name": "上海", "value": [3439.0, 4.5, "上海"]},
{"name": "四川", "value": [3241.0, 4.24, "四川"]},
{"name": "福建", "value": [2871.0, 3.75, "福建"]},
{"name": "湖北", "value": [2856.0, 3.73, "湖北"]},
{"name": "湖南", "value": [2849.0, 3.72, "湖南"]},
{"name": "黑龙江", "value": [2668.0, 3.49, "黑龙江"]},
{"name": "安徽", "value": [2347.0, 3.07, "安徽"]},
{"name": "北京", "value": [2077.0, 2.72, "北京"]},
{"name": "广西", "value": [1817.0, 2.38, "广西"]},
{"name": "云南", "value": [1676.0, 2.19, "云南"]},
{"name": "江西", "value": [1606.0, 2.1, "江西"]},
{"name": "重庆", "value": [1510.0, 1.97, "重庆"]},
{"name": "山西", "value": [1476.0, 1.93, "山西"]},
{"name": "吉林", "value": [1464.0, 1.91, "吉林"]},
{"name": "陕西", "value": [1364.0, 1.78, "陕西"]},
{"name": "天津", "value": [1265.0, 1.65, "天津"]},
{"name": "内蒙古", "value": [1154.0, 1.51, "内蒙古"]},
{"name": "新疆", "value": [1040.0, 1.36, "新疆"]},
{"name": "贵州", "value": [806.0, 1.05, "贵州"]},
{"name": "甘肃", "value": [794.0, 1.04, "甘肃"]},
{"name": "海南", "value": [411.0, 0.54, "海南"]},
{"name": "宁夏", "value": [225.0, 0.29, "宁夏"]},
{"name": "青海", "value": [203.0, 0.27, "青海"]},
{"name": "西藏", "value": [77.0, 0.1, "西藏"]},
],
},
{
"time": "1998年",
"data": [
{"name": "广东", "value": [8531.0, 10.31, "广东"]},
{"name": "江苏", "value": [7200.0, 8.7, "江苏"]},
{"name": "山东", "value": [7021.0, 8.49, "山东"]},
{"name": "浙江", "value": [5053.0, 6.11, "浙江"]},
{"name": "河南", "value": [4308.0, 5.21, "河南"]},
{"name": "河北", "value": [4256.0, 5.15, "河北"]},
{"name": "辽宁", "value": [3882.0, 4.69, "辽宁"]},
{"name": "上海", "value": [3801.0, 4.59, "上海"]},
{"name": "四川", "value": [3474.0, 4.2, "四川"]},
{"name": "福建", "value": [3160.0, 3.82, "福建"]},
{"name": "湖北", "value": [3114.0, 3.76, "湖北"]},
{"name": "湖南", "value": [3026.0, 3.66, "湖南"]},
{"name": "黑龙江", "value": [2774.0, 3.35, "黑龙江"]},
{"name": "安徽", "value": [2543.0, 3.07, "安徽"]},
{"name": "北京", "value": [2377.0, 2.87, "北京"]},
{"name": "广西", "value": [1911.0, 2.31, "广西"]},
{"name": "云南", "value": [1831.0, 2.21, "云南"]},
{"name": "江西", "value": [1720.0, 2.08, "江西"]},
{"name": "山西", "value": [1611.0, 1.95, "山西"]},
{"name": "重庆", "value": [1602.0, 1.94, "重庆"]},
{"name": "吉林", "value": [1577.0, 1.91, "吉林"]},
{"name": "陕西", "value": [1458.0, 1.76, "陕西"]},
{"name": "天津", "value": [1375.0, 1.66, "天津"]},
{"name": "内蒙古", "value": [1263.0, 1.53, "内蒙古"]},
{"name": "新疆", "value": [1107.0, 1.34, "新疆"]},
{"name": "甘肃", "value": [888.0, 1.07, "甘肃"]},
{"name": "贵州", "value": [858.0, 1.04, "贵州"]},
{"name": "海南", "value": [442.0, 0.53, "海南"]},
{"name": "宁夏", "value": [245.0, 0.3, "宁夏"]},
{"name": "青海", "value": [221.0, 0.27, "青海"]},
{"name": "西藏", "value": [92.0, 0.11, "西藏"]},
],
},
{
"time": "1999年",
"data": [
{"name": "广东", "value": [9251.0, 10.47, "广东"]},
{"name": "江苏", "value": [7698.0, 8.71, "江苏"]},
{"name": "山东", "value": [7494.0, 8.48, "山东"]},
{"name": "浙江", "value": [5444.0, 6.16, "浙江"]},
{"name": "河南", "value": [4518.0, 5.11, "河南"]},
{"name": "河北", "value": [4514.0, 5.11, "河北"]},
{"name": "上海", "value": [4189.0, 4.74, "上海"]},
{"name": "辽宁", "value": [4172.0, 4.72, "辽宁"]},
{"name": "四川", "value": [3649.0, 4.13, "四川"]},
{"name": "福建", "value": [3414.0, 3.86, "福建"]},
{"name": "湖北", "value": [3229.0, 3.65, "湖北"]},
{"name": "湖南", "value": [3215.0, 3.64, "湖南"]},
{"name": "黑龙江", "value": [2866.0, 3.24, "黑龙江"]},
{"name": "安徽", "value": [2712.0, 3.07, "安徽"]},
{"name": "北京", "value": [2679.0, 3.03, "北京"]},
{"name": "广西", "value": [1971.0, 2.23, "广西"]},
{"name": "云南", "value": [1900.0, 2.15, "云南"]},
{"name": "江西", "value": [1854.0, 2.1, "江西"]},
{"name": "吉林", "value": [1673.0, 1.89, "吉林"]},
{"name": "山西", "value": [1667.0, 1.89, "山西"]},
{"name": "重庆", "value": [1663.0, 1.88, "重庆"]},
{"name": "陕西", "value": [1593.0, 1.8, "陕西"]},
{"name": "天津", "value": [1501.0, 1.7, "天津"]},
{"name": "内蒙古", "value": [1379.0, 1.56, "内蒙古"]},
{"name": "新疆", "value": [1163.0, 1.32, "新疆"]},
{"name": "甘肃", "value": [956.0, 1.08, "甘肃"]},
{"name": "贵州", "value": [938.0, 1.06, "贵州"]},
{"name": "海南", "value": [477.0, 0.54, "海南"]},
{"name": "宁夏", "value": [265.0, 0.3, "宁夏"]},
{"name": "青海", "value": [239.0, 0.27, "青海"]},
{"name": "西藏", "value": [106.0, 0.12, "西藏"]},
],
},
{
"time": "2000年",
"data": [
{"name": "广东", "value": [10741.0, 10.88, "广东"]},
{"name": "江苏", "value": [8554.0, 8.67, "江苏"]},
{"name": "山东", "value": [8337.0, 8.45, "山东"]},
{"name": "浙江", "value": [6141.0, 6.22, "浙江"]},
{"name": "河南", "value": [5053.0, 5.12, "河南"]},
{"name": "河北", "value": [5044.0, 5.11, "河北"]},
{"name": "上海", "value": [4771.0, 4.83, "上海"]},
{"name": "辽宁", "value": [4669.0, 4.73, "辽宁"]},
{"name": "四川", "value": [3928.0, 3.98, "四川"]},
{"name": "福建", "value": [3765.0, 3.81, "福建"]},
{"name": "湖南", "value": [3551.0, 3.6, "湖南"]},
{"name": "湖北", "value": [3545.0, 3.59, "湖北"]},
{"name": "北京", "value": [3162.0, 3.2, "北京"]},
{"name": "黑龙江", "value": [3151.0, 3.19, "黑龙江"]},
{"name": "安徽", "value": [2902.0, 2.94, "安徽"]},
{"name": "广西", "value": [2080.0, 2.11, "广西"]},
{"name": "云南", "value": [2011.0, 2.04, "云南"]},
{"name": "江西", "value": [2003.0, 2.03, "江西"]},
{"name": "吉林", "value": [1952.0, 1.98, "吉林"]},
{"name": "山西", "value": [1846.0, 1.87, "山西"]},
{"name": "陕西", "value": [1804.0, 1.83, "陕西"]},
{"name": "重庆", "value": [1791.0, 1.81, "重庆"]},
{"name": "天津", "value": [1702.0, 1.72, "天津"]},
{"name": "内蒙古", "value": [1539.0, 1.56, "内蒙古"]},
{"name": "新疆", "value": [1364.0, 1.38, "新疆"]},
{"name": "甘肃", "value": [1053.0, 1.07, "甘肃"]},
{"name": "贵州", "value": [1030.0, 1.04, "贵州"]},
{"name": "海南", "value": [527.0, 0.53, "海南"]},
{"name": "宁夏", "value": [295.0, 0.3, "宁夏"]},
{"name": "青海", "value": [264.0, 0.27, "青海"]},
{"name": "西藏", "value": [118.0, 0.12, "西藏"]},
],
},
{
"time": "2001年",
"data": [
{"name": "广东", "value": [12039.0, 11.07, "广东"]},
{"name": "江苏", "value": [9457.0, 8.69, "江苏"]},
{"name": "山东", "value": [9195.0, 8.45, "山东"]},
{"name": "浙江", "value": [6898.0, 6.34, "浙江"]},
{"name": "河南", "value": [5533.0, 5.09, "河南"]},
{"name": "河北", "value": [5517.0, 5.07, "河北"]},
{"name": "上海", "value": [5210.0, 4.79, "上海"]},
{"name": "辽宁", "value": [5033.0, 4.63, "辽宁"]},
{"name": "四川", "value": [4293.0, 3.95, "四川"]},
{"name": "福建", "value": [4073.0, 3.74, "福建"]},
{"name": "湖北", "value": [3881.0, 3.57, "湖北"]},
{"name": "湖南", "value": [3832.0, 3.52, "湖南"]},
{"name": "北京", "value": [3708.0, 3.41, "北京"]},
{"name": "黑龙江", "value": [3390.0, 3.12, "黑龙江"]},
{"name": "安徽", "value": [3247.0, 2.99, "安徽"]},
{"name": "广西", "value": [2279.0, 2.1, "广西"]},
{"name": "江西", "value": [2176.0, 2.0, "江西"]},
{"name": "云南", "value": [2138.0, 1.97, "云南"]},
{"name": "吉林", "value": [2120.0, 1.95, "吉林"]},
{"name": "山西", "value": [2030.0, 1.87, "山西"]},
{"name": "陕西", "value": [2011.0, 1.85, "陕西"]},
{"name": "重庆", "value": [1977.0, 1.82, "重庆"]},
{"name": "天津", "value": [1919.0, 1.76, "天津"]},
{"name": "内蒙古", "value": [1714.0, 1.58, "内蒙古"]},
{"name": "新疆", "value": [1492.0, 1.37, "新疆"]},
{"name": "贵州", "value": [1133.0, 1.04, "贵州"]},
{"name": "甘肃", "value": [1125.0, 1.03, "甘肃"]},
{"name": "海南", "value": [579.0, 0.53, "海南"]},
{"name": "宁夏", "value": [337.0, 0.31, "宁夏"]},
{"name": "青海", "value": [300.0, 0.28, "青海"]},
{"name": "西藏", "value": [139.0, 0.13, "西藏"]},
],
},
{
"time": "2002年",
"data": [
{"name": "广东", "value": [13502.0, 11.18, "广东"]},
{"name": "江苏", "value": [10607.0, 8.78, "江苏"]},
{"name": "山东", "value": [10276.0, 8.51, "山东"]},
{"name": "浙江", "value": [8004.0, 6.62, "浙江"]},
{"name": "河南", "value": [6035.0, 4.99, "河南"]},
{"name": "河北", "value": [6018.0, 4.98, "河北"]},
{"name": "上海", "value": [5741.0, 4.75, "上海"]},
{"name": "辽宁", "value": [5458.0, 4.52, "辽宁"]},
{"name": "四川", "value": [4725.0, 3.91, "四川"]},
{"name": "福建", "value": [4468.0, 3.7, "福建"]},
{"name": "北京", "value": [4315.0, 3.57, "北京"]},
{"name": "湖北", "value": [4213.0, 3.49, "湖北"]},
{"name": "湖南", "value": [4152.0, 3.44, "湖南"]},
{"name": "黑龙江", "value": [3637.0, 3.01, "黑龙江"]},
{"name": "安徽", "value": [3520.0, 2.91, "安徽"]},
{"name": "广西", "value": [2524.0, 2.09, "广西"]},
{"name": "江西", "value": [2450.0, 2.03, "江西"]},
{"name": "吉林", "value": [2349.0, 1.94, "吉林"]},
{"name": "山西", "value": [2325.0, 1.92, "山西"]},
{"name": "云南", "value": [2313.0, 1.91, "云南"]},
{"name": "陕西", "value": [2253.0, 1.86, "陕西"]},
{"name": "重庆", "value": [2233.0, 1.85, "重庆"]},
{"name": "天津", "value": [2151.0, 1.78, "天津"]},
{"name": "内蒙古", "value": [1941.0, 1.61, "内蒙古"]},
{"name": "新疆", "value": [1613.0, 1.34, "新疆"]},
{"name": "贵州", "value": [1243.0, 1.03, "贵州"]},
{"name": "甘肃", "value": [1232.0, 1.02, "甘肃"]},
{"name": "海南", "value": [643.0, 0.53, "海南"]},
{"name": "宁夏", "value": [377.0, 0.31, "宁夏"]},
{"name": "青海", "value": [341.0, 0.28, "青海"]},
{"name": "西藏", "value": [162.0, 0.13, "西藏"]},
],
},
{
"time": "2003年",
"data": [
{"name": "广东", "value": [15845.0, 11.36, "广东"]},
{"name": "江苏", "value": [12443.0, 8.92, "江苏"]},
{"name": "山东", "value": [12078.0, 8.66, "山东"]},
{"name": "浙江", "value": [9705.0, 6.96, "浙江"]},
{"name": "河北", "value": [6921.0, 4.96, "河北"]},
{"name": "河南", "value": [6868.0, 4.92, "河南"]},
{"name": "上海", "value": [6694.0, 4.8, "上海"]},
{"name": "辽宁", "value": [6003.0, 4.3, "辽宁"]},
{"name": "四川", "value": [5333.0, 3.82, "四川"]},
{"name": "北京", "value": [5007.0, 3.59, "北京"]},
{"name": "福建", "value": [4984.0, 3.57, "福建"]},
{"name": "湖北", "value": [4757.0, 3.41, "湖北"]},
{"name": "湖南", "value": [4660.0, 3.34, "湖南"]},
{"name": "黑龙江", "value": [4057.0, 2.91, "黑龙江"]},
{"name": "安徽", "value": [3923.0, 2.81, "安徽"]},
{"name": "山西", "value": [2855.0, 2.05, "山西"]},
{"name": "广西", "value": [2821.0, 2.02, "广西"]},
{"name": "江西", "value": [2807.0, 2.01, "江西"]},
{"name": "吉林", "value": [2662.0, 1.91, "吉林"]},
{"name": "陕西", "value": [2588.0, 1.85, "陕西"]},
{"name": "天津", "value": [2578.0, 1.85, "天津"]},
{"name": "云南", "value": [2556.0, 1.83, "云南"]},
{"name": "重庆", "value": [2556.0, 1.83, "重庆"]},
{"name": "内蒙古", "value": [2388.0, 1.71, "内蒙古"]},
{"name": "新疆", "value": [1886.0, 1.35, "新疆"]},
{"name": "贵州", "value": [1426.0, 1.02, "贵州"]},
{"name": "甘肃", "value": [1400.0, 1.0, "甘肃"]},
{"name": "海南", "value": [714.0, 0.51, "海南"]},
{"name": "宁夏", "value": [445.0, 0.32, "宁夏"]},
{"name": "青海", "value": [390.0, 0.28, "青海"]},
{"name": "西藏", "value": [185.0, 0.13, "西藏"]},
],
},
{
"time": "2004年",
"data": [
{"name": "广东", "value": [18865.0, 11.23, "广东"]},
{"name": "山东", "value": [15022.0, 8.95, "山东"]},
{"name": "江苏", "value": [15004.0, 8.93, "江苏"]},
{"name": "浙江", "value": [11649.0, 6.94, "浙江"]},
{"name": "河南", "value": [8554.0, 5.09, "河南"]},
{"name": "河北", "value": [8478.0, 5.05, "河北"]},
{"name": "上海", "value": [8073.0, 4.81, "上海"]},
{"name": "辽宁", "value": [6672.0, 3.97, "辽宁"]},
{"name": "四川", "value": [6380.0, 3.8, "四川"]},
{"name": "北京", "value": [6033.0, 3.59, "北京"]},
{"name": "福建", "value": [5763.0, 3.43, "福建"]},
{"name": "湖南", "value": [5642.0, 3.36, "湖南"]},
{"name": "湖北", "value": [5633.0, 3.35, "湖北"]},
{"name": "安徽", "value": [4759.0, 2.83, "安徽"]},
{"name": "黑龙江", "value": [4751.0, 2.83, "黑龙江"]},
{"name": "山西", "value": [3571.0, 2.13, "山西"]},
{"name": "江西", "value": [3457.0, 2.06, "江西"]},
{"name": "广西", "value": [3434.0, 2.04, "广西"]},
{"name": "陕西", "value": [3176.0, 1.89, "陕西"]},
{"name": "吉林", "value": [3122.0, 1.86, "吉林"]},
{"name": "天津", "value": [3111.0, 1.85, "天津"]},
{"name": "云南", "value": [3082.0, 1.84, "云南"]},
{"name": "内蒙古", "value": [3041.0, 1.81, "内蒙古"]},
{"name": "重庆", "value": [3035.0, 1.81, "重庆"]},
{"name": "新疆", "value": [2209.0, 1.32, "新疆"]},
{"name": "甘肃", "value": [1688.0, 1.01, "甘肃"]},
{"name": "贵州", "value": [1678.0, 1.0, "贵州"]},
{"name": "海南", "value": [820.0, 0.49, "海南"]},
{"name": "宁夏", "value": [537.0, 0.32, "宁夏"]},
{"name": "青海", "value": [466.0, 0.28, "青海"]},
{"name": "西藏", "value": [220.0, 0.13, "西藏"]},
],
},
{
"time": "2005年",
"data": [
{"name": "广东", "value": [22557.0, 11.32, "广东"]},
{"name": "江苏", "value": [18599.0, 9.34, "江苏"]},
{"name": "山东", "value": [18367.0, 9.22, "山东"]},
{"name": "浙江", "value": [13418.0, 6.73, "浙江"]},
{"name": "河南", "value": [10587.0, 5.31, "河南"]},
{"name": "河北", "value": [10012.0, 5.03, "河北"]},
{"name": "上海", "value": [9248.0, 4.64, "上海"]},
{"name": "辽宁", "value": [8047.0, 4.04, "辽宁"]},
{"name": "四川", "value": [7385.0, 3.71, "四川"]},
{"name": "北京", "value": [6970.0, 3.5, "北京"]},
{"name": "湖南", "value": [6596.0, 3.31, "湖南"]},
{"name": "湖北", "value": [6590.0, 3.31, "湖北"]},
{"name": "福建", "value": [6555.0, 3.29, "福建"]},
{"name": "黑龙江", "value": [5514.0, 2.77, "黑龙江"]},
{"name": "安徽", "value": [5350.0, 2.69, "安徽"]},
{"name": "山西", "value": [4231.0, 2.12, "山西"]},
{"name": "江西", "value": [4057.0, 2.04, "江西"]},
{"name": "广西", "value": [3984.0, 2.0, "广西"]},
{"name": "陕西", "value": [3934.0, 1.97, "陕西"]},
{"name": "天津", "value": [3906.0, 1.96, "天津"]},
{"name": "内蒙古", "value": [3905.0, 1.96, "内蒙古"]},
{"name": "吉林", "value": [3620.0, 1.82, "吉林"]},
{"name": "重庆", "value": [3468.0, 1.74, "重庆"]},
{"name": "云南", "value": [3463.0, 1.74, "云南"]},
{"name": "新疆", "value": [2604.0, 1.31, "新疆"]},
{"name": "贵州", "value": [2005.0, 1.01, "贵州"]},
{"name": "甘肃", "value": [1934.0, 0.97, "甘肃"]},
{"name": "海南", "value": [919.0, 0.46, "海南"]},
{"name": "宁夏", "value": [613.0, 0.31, "宁夏"]},
{"name": "青海", "value": [543.0, 0.27, "青海"]},
{"name": "西藏", "value": [249.0, 0.12, "西藏"]},
],
},
{
"time": "2006年",
"data": [
{"name": "广东", "value": [26588.0, 11.42, "广东"]},
{"name": "山东", "value": [21900.0, 9.41, "山东"]},
{"name": "江苏", "value": [21742.0, 9.34, "江苏"]},
{"name": "浙江", "value": [15718.0, 6.75, "浙江"]},
{"name": "河南", "value": [12363.0, 5.31, "河南"]},
{"name": "河北", "value": [11468.0, 4.93, "河北"]},
{"name": "上海", "value": [10572.0, 4.54, "上海"]},
{"name": "辽宁", "value": [9305.0, 4.0, "辽宁"]},
{"name": "四川", "value": [8690.0, 3.73, "四川"]},
{"name": "北京", "value": [8118.0, 3.49, "北京"]},
{"name": "湖南", "value": [7689.0, 3.3, "湖南"]},
{"name": "湖北", "value": [7617.0, 3.27, "湖北"]},
{"name": "福建", "value": [7584.0, 3.26, "福建"]},
{"name": "黑龙江", "value": [6212.0, 2.67, "黑龙江"]},
{"name": "安徽", "value": [6113.0, 2.63, "安徽"]},
{"name": "内蒙古", "value": [4944.0, 2.12, "内蒙古"]},
{"name": "山西", "value": [4879.0, 2.1, "山西"]},
{"name": "江西", "value": [4821.0, 2.07, "江西"]},
{"name": "广西", "value": [4746.0, 2.04, "广西"]},
{"name": "陕西", "value": [4744.0, 2.04, "陕西"]},
{"name": "天津", "value": [4463.0, 1.92, "天津"]},
{"name": "吉林", "value": [4275.0, 1.84, "吉林"]},
{"name": "云南", "value": [3988.0, 1.71, "云南"]},
{"name": "重庆", "value": [3907.0, 1.68, "重庆"]},
{"name": "新疆", "value": [3045.0, 1.31, "新疆"]},
{"name": "贵州", "value": [2339.0, 1.0, "贵州"]},
{"name": "甘肃", "value": [2277.0, 0.98, "甘肃"]},
{"name": "海南", "value": [1066.0, 0.46, "海南"]},
{"name": "宁夏", "value": [726.0, 0.31, "宁夏"]},
{"name": "青海", "value": [649.0, 0.28, "青海"]},
{"name": "西藏", "value": [291.0, 0.12, "西藏"]},
],
},
{
"time": "2007年",
"data": [
{"name": "广东", "value": [31777.0, 11.36, "广东"]},
{"name": "江苏", "value": [26018.0, 9.3, "江苏"]},
{"name": "山东", "value": [25777.0, 9.21, "山东"]},
{"name": "浙江", "value": [18754.0, 6.7, "浙江"]},
{"name": "河南", "value": [15012.0, 5.37, "河南"]},
{"name": "河北", "value": [13607.0, 4.86, "河北"]},
{"name": "上海", "value": [12494.0, 4.47, "上海"]},
{"name": "辽宁", "value": [11164.0, 3.99, "辽宁"]},
{"name": "四川", "value": [10562.0, 3.78, "四川"]},
{"name": "北京", "value": [9847.0, 3.52, "北京"]},
{"name": "湖南", "value": [9440.0, 3.37, "湖南"]},
{"name": "湖北", "value": [9333.0, 3.34, "湖北"]},
{"name": "福建", "value": [9249.0, 3.31, "福建"]},
{"name": "安徽", "value": [7361.0, 2.63, "安徽"]},
{"name": "黑龙江", "value": [7104.0, 2.54, "黑龙江"]},
{"name": "内蒙古", "value": [6423.0, 2.3, "内蒙古"]},
{"name": "山西", "value": [6024.0, 2.15, "山西"]},
{"name": "广西", "value": [5823.0, 2.08, "广西"]},
{"name": "江西", "value": [5800.0, 2.07, "江西"]},
{"name": "陕西", "value": [5757.0, 2.06, "陕西"]},
{"name": "吉林", "value": [5285.0, 1.89, "吉林"]},
{"name": "天津", "value": [5253.0, 1.88, "天津"]},
{"name": "云南", "value": [4773.0, 1.71, "云南"]},
{"name": "重庆", "value": [4676.0, 1.67, "重庆"]},
{"name": "新疆", "value": [3523.0, 1.26, "新疆"]},
{"name": "贵州", "value": [2884.0, 1.03, "贵州"]},
{"name": "甘肃", "value": [2704.0, 0.97, "甘肃"]},
{"name": "海南", "value": [1254.0, 0.45, "海南"]},
{"name": "宁夏", "value": [919.0, 0.33, "宁夏"]},
{"name": "青海", "value": [797.0, 0.28, "青海"]},
{"name": "西藏", "value": [341.0, 0.12, "西藏"]},
],
},
{
"time": "2008年",
"data": [
{"name": "广东", "value": [36797.0, 11.04, "广东"]},
{"name": "江苏", "value": [30982.0, 9.3, "江苏"]},
{"name": "山东", "value": [30933.0, 9.28, "山东"]},
{"name": "浙江", "value": [21463.0, 6.44, "浙江"]},
{"name": "河南", "value": [18019.0, 5.41, "河南"]},
{"name": "河北", "value": [16012.0, 4.8, "河北"]},
{"name": "上海", "value": [14070.0, 4.22, "上海"]},
{"name": "辽宁", "value": [13669.0, 4.1, "辽宁"]},
{"name": "四川", "value": [12601.0, 3.78, "四川"]},
{"name": "湖南", "value": [11555.0, 3.47, "湖南"]},
{"name": "湖北", "value": [11329.0, 3.4, "湖北"]},
{"name": "北京", "value": [11115.0, 3.33, "北京"]},
{"name": "福建", "value": [10823.0, 3.25, "福建"]},
{"name": "安徽", "value": [8852.0, 2.66, "安徽"]},
{"name": "内蒙古", "value": [8496.0, 2.55, "内蒙古"]},
{"name": "黑龙江", "value": [8314.0, 2.49, "黑龙江"]},
{"name": "山西", "value": [7315.0, 2.19, "山西"]},
{"name": "陕西", "value": [7315.0, 2.19, "陕西"]},
{"name": "广西", "value": [7021.0, 2.11, "广西"]},
{"name": "江西", "value": [6971.0, 2.09, "江西"]},
{"name": "天津", "value": [6719.0, 2.02, "天津"]},
{"name": "吉林", "value": [6426.0, 1.93, "吉林"]},
{"name": "重庆", "value": [5794.0, 1.74, "重庆"]},
{"name": "云南", "value": [5692.0, 1.71, "云南"]},
{"name": "新疆", "value": [4183.0, 1.25, "新疆"]},
{"name": "贵州", "value": [3562.0, 1.07, "贵州"]},
{"name": "甘肃", "value": [3167.0, 0.95, "甘肃"]},
{"name": "海南", "value": [1503.0, 0.45, "海南"]},
{"name": "宁夏", "value": [1204.0, 0.36, "宁夏"]},
{"name": "青海", "value": [1019.0, 0.31, "青海"]},
{"name": "西藏", "value": [395.0, 0.12, "西藏"]},
],
},
{
"time": "2009年",
"data": [
{"name": "广东", "value": [39483.0, 10.81, "广东"]},
{"name": "江苏", "value": [34457.0, 9.43, "江苏"]},
{"name": "山东", "value": [33897.0, 9.28, "山东"]},
{"name": "浙江", "value": [22990.0, 6.29, "浙江"]},
{"name": "河南", "value": [19480.0, 5.33, "河南"]},
{"name": "河北", "value": [17235.0, 4.72, "河北"]},
{"name": "辽宁", "value": [15212.0, 4.16, "辽宁"]},
{"name": "上海", "value": [15046.0, 4.12, "上海"]},
{"name": "四川", "value": [14151.0, 3.87, "四川"]},
{"name": "湖南", "value": [13060.0, 3.58, "湖南"]},
{"name": "湖北", "value": [12961.0, 3.55, "湖北"]},
{"name": "福建", "value": [12237.0, 3.35, "福建"]},
{"name": "北京", "value": [12153.0, 3.33, "北京"]},
{"name": "安徽", "value": [10063.0, 2.75, "安徽"]},
{"name": "内蒙古", "value": [9740.0, 2.67, "内蒙古"]},
{"name": "黑龙江", "value": [8587.0, 2.35, "黑龙江"]},
{"name": "陕西", "value": [8170.0, 2.24, "陕西"]},
{"name": "广西", "value": [7759.0, 2.12, "广西"]},
{"name": "江西", "value": [7655.0, 2.1, "江西"]},
{"name": "天津", "value": [7522.0, 2.06, "天津"]},
{"name": "山西", "value": [7358.0, 2.01, "山西"]},
{"name": "吉林", "value": [7279.0, 1.99, "吉林"]},
{"name": "重庆", "value": [6530.0, 1.79, "重庆"]},
{"name": "云南", "value": [6170.0, 1.69, "云南"]},
{"name": "新疆", "value": [4277.0, 1.17, "新疆"]},
{"name": "贵州", "value": [3913.0, 1.07, "贵州"]},
{"name": "甘肃", "value": [3388.0, 0.93, "甘肃"]},
{"name": "海南", "value": [1654.0, 0.45, "海南"]},
{"name": "宁夏", "value": [1353.0, 0.37, "宁夏"]},
{"name": "青海", "value": [1081.0, 0.3, "青海"]},
{"name": "西藏", "value": [441.0, 0.12, "西藏"]},
],
},
{
"time": "2010年",
"data": [
{"name": "广东", "value": [46013.0, 10.53, "广东"]},
{"name": "江苏", "value": [41425.0, 9.48, "江苏"]},
{"name": "山东", "value": [39170.0, 8.96, "山东"]},
{"name": "浙江", "value": [27722.0, 6.34, "浙江"]},
{"name": "河南", "value": [23092.0, 5.28, "河南"]},
{"name": "河北", "value": [20394.0, 4.67, "河北"]},
{"name": "辽宁", "value": [18457.0, 4.22, "辽宁"]},
{"name": "四川", "value": [17185.0, 3.93, "四川"]},
{"name": "上海", "value": [17166.0, 3.93, "上海"]},
{"name": "湖南", "value": [16038.0, 3.67, "湖南"]},
{"name": "湖北", "value": [15968.0, 3.65, "湖北"]},
{"name": "福建", "value": [14737.0, 3.37, "福建"]},
{"name": "北京", "value": [14114.0, 3.23, "北京"]},
{"name": "安徽", "value": [12359.0, 2.83, "安徽"]},
{"name": "内蒙古", "value": [11672.0, 2.67, "内蒙古"]},
{"name": "黑龙江", "value": [10369.0, 2.37, "黑龙江"]},
{"name": "陕西", "value": [10123.0, 2.32, "陕西"]},
{"name": "广西", "value": [9570.0, 2.19, "广西"]},
{"name": "江西", "value": [9451.0, 2.16, "江西"]},
{"name": "天津", "value": [9224.0, 2.11, "天津"]},
{"name": "山西", "value": [9201.0, 2.11, "山西"]},
{"name": "吉林", "value": [8668.0, 1.98, "吉林"]},
{"name": "重庆", "value": [7926.0, 1.81, "重庆"]},
{"name": "云南", "value": [7224.0, 1.65, "云南"]},
{"name": "新疆", "value": [5437.0, 1.24, "新疆"]},
{"name": "贵州", "value": [4602.0, 1.05, "贵州"]},
{"name": "甘肃", "value": [4121.0, 0.94, "甘肃"]},
{"name": "海南", "value": [2065.0, 0.47, "海南"]},
{"name": "宁夏", "value": [1690.0, 0.39, "宁夏"]},
{"name": "青海", "value": [1350.0, 0.31, "青海"]},
{"name": "西藏", "value": [507.0, 0.12, "西藏"]},
],
},
{
"time": "2011年",
"data": [
{"name": "广东", "value": [53210.0, 10.2, "广东"]},
{"name": "江苏", "value": [49110.0, 9.42, "江苏"]},
{"name": "山东", "value": [45362.0, 8.7, "山东"]},
{"name": "浙江", "value": [32319.0, 6.2, "浙江"]},
{"name": "河南", "value": [26931.0, 5.16, "河南"]},
{"name": "河北", "value": [24516.0, 4.7, "河北"]},
{"name": "辽宁", "value": [22227.0, 4.26, "辽宁"]},
{"name": "四川", "value": [21027.0, 4.03, "四川"]},
{"name": "湖南", "value": [19670.0, 3.77, "湖南"]},
{"name": "湖北", "value": [19632.0, 3.76, "湖北"]},
{"name": "上海", "value": [19196.0, 3.68, "上海"]},
{"name": "福建", "value": [17560.0, 3.37, "福建"]},
{"name": "北京", "value": [16252.0, 3.12, "北京"]},
{"name": "安徽", "value": [15301.0, 2.93, "安徽"]},
{"name": "内蒙古", "value": [14360.0, 2.75, "内蒙古"]},
{"name": "黑龙江", "value": [12582.0, 2.41, "黑龙江"]},
{"name": "陕西", "value": [12512.0, 2.4, "陕西"]},
{"name": "广西", "value": [11721.0, 2.25, "广西"]},
{"name": "江西", "value": [11703.0, 2.24, "江西"]},
{"name": "天津", "value": [11307.0, 2.17, "天津"]},
{"name": "山西", "value": [11238.0, 2.16, "山西"]},
{"name": "吉林", "value": [10569.0, 2.03, "吉林"]},
{"name": "重庆", "value": [10011.0, 1.92, "重庆"]},
{"name": "云南", "value": [8893.0, 1.71, "云南"]},
{"name": "新疆", "value": [6610.0, 1.27, "新疆"]},
{"name": "贵州", "value": [5702.0, 1.09, "贵州"]},
{"name": "甘肃", "value": [5020.0, 0.96, "甘肃"]},
{"name": "海南", "value": [2523.0, 0.48, "海南"]},
{"name": "宁夏", "value": [2102.0, 0.4, "宁夏"]},
{"name": "青海", "value": [1670.0, 0.32, "青海"]},
{"name": "西藏", "value": [606.0, 0.12, "西藏"]},
],
},
{
"time": "2012年",
"data": [
{"name": "广东", "value": [57068.0, 9.9, "广东"]},
{"name": "江苏", "value": [54058.0, 9.38, "江苏"]},
{"name": "山东", "value": [50013.0, 8.67, "山东"]},
{"name": "浙江", "value": [34665.0, 6.01, "浙江"]},
{"name": "河南", "value": [29599.0, 5.13, "河南"]},
{"name": "河北", "value": [26575.0, 4.61, "河北"]},
{"name": "辽宁", "value": [24846.0, 4.31, "辽宁"]},
{"name": "四川", "value": [23873.0, 4.14, "四川"]},
{"name": "湖北", "value": [22250.0, 3.86, "湖北"]},
{"name": "湖南", "value": [22154.0, 3.84, "湖南"]},
{"name": "上海", "value": [20182.0, 3.5, "上海"]},
{"name": "福建", "value": [19702.0, 3.42, "福建"]},
{"name": "北京", "value": [17879.0, 3.1, "北京"]},
{"name": "安徽", "value": [17212.0, 2.99, "安徽"]},
{"name": "内蒙古", "value": [15881.0, 2.75, "内蒙古"]},
{"name": "陕西", "value": [14454.0, 2.51, "陕西"]},
{"name": "黑龙江", "value": [13692.0, 2.37, "黑龙江"]},
{"name": "广西", "value": [13035.0, 2.26, "广西"]},
{"name": "江西", "value": [12949.0, 2.25, "江西"]},
{"name": "天津", "value": [12894.0, 2.24, "天津"]},
{"name": "山西", "value": [12113.0, 2.1, "山西"]},
{"name": "吉林", "value": [11939.0, 2.07, "吉林"]},
{"name": "重庆", "value": [11410.0, 1.98, "重庆"]},
{"name": "云南", "value": [10309.0, 1.79, "云南"]},
{"name": "新疆", "value": [7505.0, 1.3, "新疆"]},
{"name": "贵州", "value": [6852.0, 1.19, "贵州"]},
{"name": "甘肃", "value": [5650.0, 0.98, "甘肃"]},
{"name": "海南", "value": [2856.0, 0.5, "海南"]},
{"name": "宁夏", "value": [2341.0, 0.41, "宁夏"]},
{"name": "青海", "value": [1894.0, 0.33, "青海"]},
{"name": "西藏", "value": [701.0, 0.12, "西藏"]},
],
},
{
"time": "2013年",
"data": [
{"name": "广东", "value": [62475.0, 9.85, "广东"]},
{"name": "江苏", "value": [59753.0, 9.42, "江苏"]},
{"name": "山东", "value": [55230.0, 8.71, "山东"]},
{"name": "浙江", "value": [37757.0, 5.95, "浙江"]},
{"name": "河南", "value": [32191.0, 5.07, "河南"]},
{"name": "河北", "value": [28443.0, 4.48, "河北"]},
{"name": "辽宁", "value": [27213.0, 4.29, "辽宁"]},
{"name": "四川", "value": [26392.0, 4.16, "四川"]},
{"name": "湖北", "value": [24792.0, 3.91, "湖北"]},
{"name": "湖南", "value": [24622.0, 3.88, "湖南"]},
{"name": "福建", "value": [21868.0, 3.45, "福建"]},
{"name": "上海", "value": [21818.0, 3.44, "上海"]},
{"name": "北京", "value": [19801.0, 3.12, "北京"]},
{"name": "安徽", "value": [19229.0, 3.03, "安徽"]},
{"name": "内蒙古", "value": [16917.0, 2.67, "内蒙古"]},
{"name": "陕西", "value": [16205.0, 2.55, "陕西"]},
{"name": "黑龙江", "value": [14455.0, 2.28, "黑龙江"]},
{"name": "广西", "value": [14450.0, 2.28, "广西"]},
{"name": "天津", "value": [14442.0, 2.28, "天津"]},
{"name": "江西", "value": [14410.0, 2.27, "江西"]},
{"name": "吉林", "value": [13046.0, 2.06, "吉林"]},
{"name": "重庆", "value": [12783.0, 2.02, "重庆"]},
{"name": "山西", "value": [12665.0, 2.0, "山西"]},
{"name": "云南", "value": [11832.0, 1.87, "云南"]},
{"name": "新疆", "value": [8444.0, 1.33, "新疆"]},
{"name": "贵州", "value": [8087.0, 1.27, "贵州"]},
{"name": "甘肃", "value": [6331.0, 1.0, "甘肃"]},
{"name": "海南", "value": [3178.0, 0.5, "海南"]},
{"name": "宁夏", "value": [2578.0, 0.41, "宁夏"]},
{"name": "青海", "value": [2122.0, 0.33, "青海"]},
{"name": "西藏", "value": [816.0, 0.13, "西藏"]},
],
},
{
"time": "2014年",
"data": [
{"name": "广东", "value": [67810.0, 9.91, "广东"]},
{"name": "江苏", "value": [65088.0, 9.51, "江苏"]},
{"name": "山东", "value": [59427.0, 8.68, "山东"]},
{"name": "浙江", "value": [40173.0, 5.87, "浙江"]},
{"name": "河南", "value": [34938.0, 5.11, "河南"]},
{"name": "河北", "value": [29421.0, 4.3, "河北"]},
{"name": "辽宁", "value": [28627.0, 4.18, "辽宁"]},
{"name": "四川", "value": [28537.0, 4.17, "四川"]},
{"name": "湖北", "value": [27379.0, 4.0, "湖北"]},
{"name": "湖南", "value": [27037.0, 3.95, "湖南"]},
{"name": "福建", "value": [24056.0, 3.52, "福建"]},
{"name": "上海", "value": [23568.0, 3.44, "上海"]},
{"name": "北京", "value": [21331.0, 3.12, "北京"]},
{"name": "安徽", "value": [20849.0, 3.05, "安徽"]},
{"name": "内蒙古", "value": [17770.0, 2.6, "内蒙古"]},
{"name": "陕西", "value": [17690.0, 2.58, "陕西"]},
{"name": "天津", "value": [15727.0, 2.3, "天津"]},
{"name": "江西", "value": [15715.0, 2.3, "江西"]},
{"name": "广西", "value": [15673.0, 2.29, "广西"]},
{"name": "黑龙江", "value": [15039.0, 2.2, "黑龙江"]},
{"name": "重庆", "value": [14263.0, 2.08, "重庆"]},
{"name": "吉林", "value": [13803.0, 2.02, "吉林"]},
{"name": "云南", "value": [12815.0, 1.87, "云南"]},
{"name": "山西", "value": [12761.0, 1.86, "山西"]},
{"name": "新疆", "value": [9273.0, 1.36, "新疆"]},
{"name": "贵州", "value": [9266.0, 1.35, "贵州"]},
{"name": "甘肃", "value": [6837.0, 1.0, "甘肃"]},
{"name": "海南", "value": [3501.0, 0.51, "海南"]},
{"name": "宁夏", "value": [2752.0, 0.4, "宁夏"]},
{"name": "青海", "value": [2303.0, 0.34, "青海"]},
{"name": "西藏", "value": [921.0, 0.13, "西藏"]},
],
},
{
"time": "2015年",
"data": [
{"name": "广东", "value": [72813.0, 10.07, "广东"]},
{"name": "江苏", "value": [70116.0, 9.7, "江苏"]},
{"name": "山东", "value": [63002.0, 8.72, "山东"]},
{"name": "浙江", "value": [42886.0, 5.93, "浙江"]},
{"name": "河南", "value": [37002.0, 5.12, "河南"]},
{"name": "四川", "value": [30053.0, 4.16, "四川"]},
{"name": "河北", "value": [29806.0, 4.12, "河北"]},
{"name": "湖北", "value": [29550.0, 4.09, "湖北"]},
{"name": "湖南", "value": [28902.0, 4.0, "湖南"]},
{"name": "辽宁", "value": [28669.0, 3.97, "辽宁"]},
{"name": "福建", "value": [25980.0, 3.59, "福建"]},
{"name": "上海", "value": [25123.0, 3.48, "上海"]},
{"name": "北京", "value": [23015.0, 3.18, "北京"]},
{"name": "安徽", "value": [22006.0, 3.04, "安徽"]},
{"name": "陕西", "value": [18022.0, 2.49, "陕西"]},
{"name": "内蒙古", "value": [17832.0, 2.47, "内蒙古"]},
{"name": "广西", "value": [16803.0, 2.32, "广西"]},
{"name": "江西", "value": [16724.0, 2.31, "江西"]},
{"name": "天津", "value": [16538.0, 2.29, "天津"]},
{"name": "重庆", "value": [15717.0, 2.17, "重庆"]},
{"name": "黑龙江", "value": [15084.0, 2.09, "黑龙江"]},
{"name": "吉林", "value": [14063.0, 1.95, "吉林"]},
{"name": "云南", "value": [13619.0, 1.88, "云南"]},
{"name": "山西", "value": [12766.0, 1.77, "山西"]},
{"name": "贵州", "value": [10503.0, 1.45, "贵州"]},
{"name": "新疆", "value": [9325.0, 1.29, "新疆"]},
{"name": "甘肃", "value": [6790.0, 0.94, "甘肃"]},
{"name": "海南", "value": [3703.0, 0.51, "海南"]},
{"name": "宁夏", "value": [2912.0, 0.4, "宁夏"]},
{"name": "青海", "value": [2417.0, 0.33, "青海"]},
{"name": "西藏", "value": [1026.0, 0.14, "西藏"]},
],
},
{
"time": "2016年",
"data": [
{"name": "广东", "value": [80855.0, 10.37, "广东"]},
{"name": "江苏", "value": [77388.0, 9.92, "江苏"]},
{"name": "山东", "value": [68024.0, 8.72, "山东"]},
{"name": "浙江", "value": [47251.0, 6.06, "浙江"]},
{"name": "河南", "value": [40472.0, 5.19, "河南"]},
{"name": "四川", "value": [32935.0, 4.22, "四川"]},
{"name": "湖北", "value": [32665.0, 4.19, "湖北"]},
{"name": "河北", "value": [32070.0, 4.11, "河北"]},
{"name": "湖南", "value": [31551.0, 4.04, "湖南"]},
{"name": "福建", "value": [28811.0, 3.69, "福建"]},
{"name": "上海", "value": [28179.0, 3.61, "上海"]},
{"name": "北京", "value": [25669.0, 3.29, "北京"]},
{"name": "安徽", "value": [24408.0, 3.13, "安徽"]},
{"name": "辽宁", "value": [22247.0, 2.85, "辽宁"]},
{"name": "陕西", "value": [19400.0, 2.49, "陕西"]},
{"name": "江西", "value": [18499.0, 2.37, "江西"]},
{"name": "广西", "value": [18318.0, 2.35, "广西"]},
{"name": "内蒙古", "value": [18128.0, 2.32, "内蒙古"]},
{"name": "天津", "value": [17885.0, 2.29, "天津"]},
{"name": "重庆", "value": [17741.0, 2.27, "重庆"]},
{"name": "黑龙江", "value": [15386.0, 1.97, "黑龙江"]},
{"name": "云南", "value": [14788.0, 1.9, "云南"]},
{"name": "吉林", "value": [14777.0, 1.89, "吉林"]},
{"name": "山西", "value": [13050.0, 1.67, "山西"]},
{"name": "贵州", "value": [11777.0, 1.51, "贵州"]},
{"name": "新疆", "value": [9650.0, 1.24, "新疆"]},
{"name": "甘肃", "value": [7200.0, 0.92, "甘肃"]},
{"name": "海南", "value": [4053.0, 0.52, "海南"]},
{"name": "宁夏", "value": [3169.0, 0.41, "宁夏"]},
{"name": "青海", "value": [2572.0, 0.33, "青海"]},
{"name": "西藏", "value": [1151.0, 0.15, "西藏"]},
],
},
{
"time": "2017年",
"data": [
{"name": "广东", "value": [89705.0, 10.59, "广东"]},
{"name": "江苏", "value": [85870.0, 10.14, "江苏"]},
{"name": "山东", "value": [72634.0, 8.57, "山东"]},
{"name": "浙江", "value": [51768.0, 6.11, "浙江"]},
{"name": "河南", "value": [44553.0, 5.26, "河南"]},
{"name": "四川", "value": [36980.0, 4.37, "四川"]},
{"name": "湖北", "value": [35478.0, 4.19, "湖北"]},
{"name": "河北", "value": [34016.0, 4.02, "河北"]},
{"name": "湖南", "value": [33903.0, 4.0, "湖南"]},
{"name": "福建", "value": [32182.0, 3.8, "福建"]},
{"name": "上海", "value": [30633.0, 3.62, "上海"]},
{"name": "北京", "value": [28015.0, 3.31, "北京"]},
{"name": "安徽", "value": [27018.0, 3.19, "安徽"]},
{"name": "辽宁", "value": [23409.0, 2.76, "辽宁"]},
{"name": "陕西", "value": [21899.0, 2.59, "陕西"]},
{"name": "江西", "value": [20006.0, 2.36, "江西"]},
{"name": "重庆", "value": [19425.0, 2.29, "重庆"]},
{"name": "天津", "value": [18549.0, 2.19, "天津"]},
{"name": "广西", "value": [18523.0, 2.19, "广西"]},
{"name": "云南", "value": [16376.0, 1.93, "云南"]},
{"name": "内蒙古", "value": [16096.0, 1.9, "内蒙古"]},
{"name": "黑龙江", "value": [15903.0, 1.88, "黑龙江"]},
{"name": "山西", "value": [15528.0, 1.83, "山西"]},
{"name": "吉林", "value": [14945.0, 1.76, "吉林"]},
{"name": "贵州", "value": [13541.0, 1.6, "贵州"]},
{"name": "新疆", "value": [10882.0, 1.28, "新疆"]},
{"name": "甘肃", "value": [7460.0, 0.88, "甘肃"]},
{"name": "海南", "value": [4463.0, 0.53, "海南"]},
{"name": "宁夏", "value": [3444.0, 0.41, "宁夏"]},
{"name": "青海", "value": [2625.0, 0.31, "青海"]},
{"name": "西藏", "value": [1311.0, 0.15, "西藏"]},
],
},
{
"time": "2018年",
"data": [
{"name": "广东", "value": [97278.0, 10.63, "广东"]},
{"name": "江苏", "value": [92595.0, 10.12, "江苏"]},
{"name": "山东", "value": [76470.0, 8.36, "山东"]},
{"name": "浙江", "value": [56197.0, 6.14, "浙江"]},
{"name": "河南", "value": [48056.0, 5.25, "河南"]},
{"name": "四川", "value": [40678.0, 4.45, "四川"]},
{"name": "湖北", "value": [39367.0, 4.3, "湖北"]},
{"name": "湖南", "value": [36426.0, 3.98, "湖南"]},
{"name": "河北", "value": [36010.0, 3.94, "河北"]},
{"name": "福建", "value": [35804.0, 3.91, "福建"]},
{"name": "上海", "value": [32680.0, 3.57, "上海"]},
{"name": "北京", "value": [30320.0, 3.31, "北京"]},
{"name": "安徽", "value": [30007.0, 3.28, "安徽"]},
{"name": "辽宁", "value": [25315.0, 2.77, "辽宁"]},
{"name": "陕西", "value": [24438.0, 2.67, "陕西"]},
{"name": "江西", "value": [21985.0, 2.4, "江西"]},
{"name": "重庆", "value": [20363.0, 2.23, "重庆"]},
{"name": "广西", "value": [20353.0, 2.23, "广西"]},
{"name": "天津", "value": [18810.0, 2.06, "天津"]},
{"name": "云南", "value": [17881.0, 1.95, "云南"]},
{"name": "内蒙古", "value": [17289.0, 1.89, "内蒙古"]},
{"name": "山西", "value": [16818.0, 1.84, "山西"]},
{"name": "黑龙江", "value": [16362.0, 1.79, "黑龙江"]},
{"name": "吉林", "value": [15075.0, 1.65, "吉林"]},
{"name": "贵州", "value": [14806.0, 1.62, "贵州"]},
{"name": "新疆", "value": [12199.0, 1.33, "新疆"]},
{"name": "甘肃", "value": [8246.0, 0.9, "甘肃"]},
{"name": "海南", "value": [4832.0, 0.53, "海南"]},
{"name": "宁夏", "value": [3705.0, 0.41, "宁夏"]},
{"name": "青海", "value": [2865.0, 0.31, "青海"]},
{"name": "西藏", "value": [1478.0, 0.16, "西藏"]},
],
},
]
time_list = [str(d) + "年" for d in range(1993, 2019)]
total_num = [
3.4,
4.5,
5.8,
6.8,
7.6,
8.3,
8.8,
9.9,
10.9,
12.1,
14,
16.8,
19.9,
23.3,
28,
33.3,
36.5,
43.7,
52.1,
57.7,
63.4,
68.4,
72.3,
78,
84.7,
91.5,
]
maxNum = 97300
minNum = 30
def rose_base():
rose = (
Pie()
.add(
"",
[list(z) for z in zip(['可乐', '雪碧', '橙汁', '绿茶', '百威'], list(range(20, 70, 10)))],
radius=["30%", "75%"],
center=["25%", "50%"],
rosetype="radius",
)
.add(
"",
[list(z) for z in zip(['草莓', '芒果', '葡萄', '雪梨', '西瓜'], list(range(10, 50, 10))[::-1])],
radius=["30%", "75%"],
center=["75%", "50%"],
rosetype="area",
)
.set_global_opts(title_opts=opts.TitleOpts(title="单定性变量-玫瑰图"))
)
return rose
def get_year_chart(year: str):
map_data = [
[[x["name"], x["value"]] for x in d["data"]] for d in data if d["time"] == year
][0]
min_data, max_data = (minNum, maxNum)
data_mark: List = []
i = 0
for x in time_list:
if x == year:
data_mark.append(total_num[i])
else:
data_mark.append("")
i = i + 1
map_chart = (
Map()
.add(
series_name="",
data_pair=map_data,
zoom=1,
center=[119.5, 34.5],
is_map_symbol_show=False,
itemstyle_opts={
"normal": {"areaColor": "#323c48", "borderColor": "#404a59"},
"emphasis": {
"label": {"show": Timeline},
"areaColor": "rgba(255,255,255, 0.5)",
},
},
)
.set_global_opts(
title_opts=opts.TitleOpts(
title="" + str(year) + "全国分地区GPD情况(单位:亿) 数据来源:国家统计局",
subtitle="",
pos_left="center",
pos_top="top",
title_textstyle_opts=opts.TextStyleOpts(
font_size=25, color="rgba(255,255,255, 0.9)"
),
),
tooltip_opts=opts.TooltipOpts(
is_show=True,
formatter=JsCode(
"""function(params) {
if ('value' in params.data) {
return params.data.value[2] + ': ' + params.data.value[0];
}
}"""
),
),
visualmap_opts=opts.VisualMapOpts(
is_calculable=True,
dimension=0,
pos_left="30",
pos_top="center",
range_text=["High", "Low"],
range_color=["lightskyblue", "yellow", "orangered"],
textstyle_opts=opts.TextStyleOpts(color="#ddd"),
min_=min_data,
max_=max_data,
),
)
)
line_chart = (
Line()
.add_xaxis(time_list)
.add_yaxis("", total_num)
.add_yaxis(
"",
data_mark,
markpoint_opts=opts.MarkPointOpts(data=[opts.MarkPointItem(type_="max")]),
)
.set_series_opts(label_opts=opts.LabelOpts(is_show=False))
.set_global_opts(
title_opts=opts.TitleOpts(
title="全国GDP总量1993-2018年(单位:万亿)", pos_left="72%", pos_top="5%"
)
)
)
bar_x_data = [x[0] for x in map_data]
bar_y_data = [{"name": x[0], "value": x[1][0]} for x in map_data]
bar = (
Bar()
.add_xaxis(xaxis_data=bar_x_data)
.add_yaxis(
series_name="",
y_axis=bar_y_data,
label_opts=opts.LabelOpts(
is_show=True, position="right", formatter="{b} : {c}"
),
)
.reversal_axis()
.set_global_opts(
xaxis_opts=opts.AxisOpts(
max_=maxNum, axislabel_opts=opts.LabelOpts(is_show=False)
),
yaxis_opts=opts.AxisOpts(axislabel_opts=opts.LabelOpts(is_show=False)),
tooltip_opts=opts.TooltipOpts(is_show=False),
visualmap_opts=opts.VisualMapOpts(
is_calculable=True,
dimension=0,
pos_left="10",
pos_top="top",
range_text=["High", "Low"],
range_color=["lightskyblue", "yellow", "orangered"],
textstyle_opts=opts.TextStyleOpts(color="#ddd"),
min_=min_data,
max_=max_data,
),
)
)
pie_data = [[x[0], x[1][0]] for x in map_data]
pie = (
Pie()
.add(
series_name="",
data_pair=pie_data,
radius=["15%", "35%"],
center=["80%", "82%"],
itemstyle_opts=opts.ItemStyleOpts(
border_width=1, border_color="rgba(0,0,0,0.3)"
),
)
.set_global_opts(
tooltip_opts=opts.TooltipOpts(is_show=True, formatter="{b} {d}%"),
legend_opts=opts.LegendOpts(is_show=False),
)
)
grid_chart = (
Grid()
.add(
bar,
grid_opts=opts.GridOpts(
pos_left="10", pos_right="45%", pos_top="50%", pos_bottom="5"
),
)
.add(
line_chart,
grid_opts=opts.GridOpts(
pos_left="65%", pos_right="80", pos_top="10%", pos_bottom="50%"
),
)
.add(pie, grid_opts=opts.GridOpts(pos_left="45%", pos_top="60%"))
.add(map_chart, grid_opts=opts.GridOpts())
)
return grid_chart
def map_base():
if __name__ == "__main__":
timeline = Timeline(
init_opts=opts.InitOpts(width="1600px", height="900px", theme=ThemeType.DARK)
)
for y in time_list:
g = get_year_chart(year=y)
timeline.add(g, time_point=str(y))
timeline.add_schema(
orient="vertical",
is_auto_play=True,
is_inverse=True,
play_interval=500,
pos_left="null",
pos_right="5",
pos_top="20",
pos_bottom="20",
width="60",
label_opts=opts.LabelOpts(is_show=True, color="#fff"),
)
return timeline
def pie_base():
chinaAbsPie = (
Pie()
.add_dataset(
source=[
["product", "2012", "2013", "2014", "2015", "2016", "2017"],
["Matcha Latte", 41.1, 30.4, 65.1, 53.3, 83.8, 98.7],
["Milk Tea", 86.5, 92.1, 85.7, 83.1, 73.4, 55.1],
["Cheese Cocoa", 24.1, 67.2, 79.5, 86.4, 65.2, 82.5],
["Walnut Brownie", 55.2, 67.1, 69.2, 72.4, 53.9, 39.1],
]
)
.add(
series_name="Matcha Latte",
data_pair=[],
radius=60,
center=["25%", "30%"],
encode={"itemName": "product", "value": "2012"},
)
.add(
series_name="Milk Tea",
data_pair=[],
radius=60,
center=["75%", "30%"],
encode={"itemName": "product", "value": "2013"},
)
.add(
series_name="Cheese Cocoa",
data_pair=[],
radius=60,
center=["25%", "75%"],
encode={"itemName": "product", "value": "2014"},
)
.add(
series_name="Walnut Brownie",
data_pair=[],
radius=60,
center=["75%", "75%"],
encode={"itemName": "product", "value": "2015"},
)
.set_global_opts(
title_opts=opts.TitleOpts(title="定性单变量-饼图", subtitle="Pie"),
legend_opts=opts.LegendOpts(pos_left="30%", pos_top="2%"),
)
)
return chinaAbsPie
def hist_base():
histogram = (
Bar()
.add_xaxis([1, 2, 3, 4, 5, 6, 7])
.add_yaxis("商家A", [39, 32, 119, 150, 106, 145, 140], category_gap=0, color='#2eb6aa')
.set_global_opts(title_opts=opts.TitleOpts(title="Bar-直方图"))
)
return histogram
def box_base():
v1 = [
[850, 740, 900, 1070, 930, 850, 950, 980, 980, 880, 1000, 980],
[960, 940, 960, 940, 480, 400, 850, 880, 400, 840, 830, 790],
]
v2 = [
[890, 810, 810, 820, 800, 770, 760, 740, 750, 760, 910, 920],
[890, 840, 780, 810, 760, 810, 790, 810, 820, 850, 870, 870],
]
c = Boxplot()
c.add_xaxis(["expr1", "expr2"])
c.add_yaxis("A", c.prepare_data(v1))
c.add_yaxis("B", c.prepare_data(v2))
c.set_global_opts(title_opts=opts.TitleOpts(title="BoxPlot-基本示例"))
return c
def spChart_base():
Area_map = (
Line()
.add_xaxis([1, 2, 3, 4, 5, 6, 7])
.add_yaxis("商家A", [61, 24, 30, 135, 141, 114, 31], is_smooth=True) # Faker.values()
.add_yaxis("商家B", [30, 86, 88, 116, 44, 91, 111], is_smooth=True) # Faker.values()
.set_series_opts(
areastyle_opts=opts.AreaStyleOpts(opacity=0.5),
label_opts=opts.LabelOpts(is_show=False),
)
.set_global_opts(
title_opts=opts.TitleOpts(title="单变量-面积图(紧贴 Y 轴)"),
xaxis_opts=opts.AxisOpts(
axistick_opts=opts.AxisTickOpts(is_align_with_label=True),
is_scale=False,
boundary_gap=False,
),
)
)
return Area_map
def Scatter_base():
Scatte = (
Scatter()
.add_xaxis(['可乐', '雪碧', '橙汁', '绿茶', '奶茶', '百威', '青岛'])
.add_yaxis("商家A", [78, 43, 60, 47, 146, 41, 129])
.add_yaxis("商家B", [70, 72, 108, 85, 78, 83, 52])
.set_global_opts(
title_opts=opts.TitleOpts(title="定量和定量-散点图Scatter-VisualMap(Size)"),
visualmap_opts=opts.VisualMapOpts(type_="size", max_=150, min_=20),
)
)
return Scatte
def stacked_columns_base():
list2 = [
{"value": 12, "percent": 12 / (12 + 3)},
{"value": 23, "percent": 23 / (23 + 21)},
{"value": 33, "percent": 33 / (33 + 5)},
{"value": 3, "percent": 3 / (3 + 52)},
{"value": 33, "percent": 33 / (33 + 43)},
]
list3 = [
{"value": 3, "percent": 3 / (12 + 3)},
{"value": 21, "percent": 21 / (23 + 21)},
{"value": 5, "percent": 5 / (33 + 5)},
{"value": 52, "percent": 52 / (3 + 52)},
{"value": 43, "percent": 43 / (33 + 43)},
]
Stacked_column = (
Bar()##init_opts=opts.InitOpts(theme=ThemeType.DARK)
.add_xaxis([1, 2, 3, 4, 5])
.add_yaxis("product1", list2, stack="stack1", category_gap="50%")
.add_yaxis("product2", list3, stack="stack1", category_gap="50%")
.set_series_opts(
label_opts=opts.LabelOpts(
position="right",
formatter=JsCode(
"function(x){return Number(x.data.percent * 100).toFixed() + '%';}"
),
)
)
)
return Stacked_column
def line_chart_base():
week_name_list = ["周一", "周二", "周三", "周四", "周五", "周六", "周日"]
high_temperature = [11, 11, 15, 13, 12, 13, 10]
low_temperature = [1, -2, 2, 5, 3, 2, 0]
Line_chart1 = (
Line(init_opts=opts.InitOpts(width="1600px", height="800px"))
.add_xaxis(xaxis_data=week_name_list)
.add_yaxis(
series_name="最高气温",
y_axis=high_temperature,
markpoint_opts=opts.MarkPointOpts(
data=[
opts.MarkPointItem(type_="max", name="最大值"),
opts.MarkPointItem(type_="min", name="最小值"),
]
),
markline_opts=opts.MarkLineOpts(
data=[opts.MarkLineItem(type_="average", name="平均值")]
),
)
.add_yaxis(
series_name="最低气温",
y_axis=low_temperature,
markpoint_opts=opts.MarkPointOpts(
data=[opts.MarkPointItem(value=-2, name="周最低", x=1, y=-1.5)]
),
markline_opts=opts.MarkLineOpts(
data=[
opts.MarkLineItem(type_="average", name="平均值"),
opts.MarkLineItem(symbol="none", x="90%", y="max"),
opts.MarkLineItem(symbol="circle", type_="max", name="最高点"),
]
),
)
.set_global_opts(
title_opts=opts.TitleOpts(title="未来一周气温变化", subtitle="纯属虚构"),
tooltip_opts=opts.TooltipOpts(trigger="axis"),
toolbox_opts=opts.ToolboxOpts(is_show=True),
xaxis_opts=opts.AxisOpts(type_="category", boundary_gap=False),
)
# .render("temperature_change_line_chart.html")
)
return Line_chart1
def bar_chart_base():
Uniqualitative_variable_graph = (
Bar()
.add_xaxis(['草莓', '芒果', '葡萄', '雪梨', '西瓜', '柠檬', '车厘子']) # Faker.choose()
.add_yaxis("商家A", [148, 143, 70, 76, 100, 98, 85]) # Faker.values()
.add_yaxis("商家B", [139, 117, 146, 114, 114, 131, 138]) # Faker.values()
.set_global_opts(
title_opts=opts.TitleOpts(title="定性单变量-柱形图", subtitle="Bar-Brush"),
brush_opts=opts.BrushOpts(),
)
)
return Uniqualitative_variable_graph
@app.route("/")
def index():
return render_template("index.html")
@app.route("/bar")
def barChart():
return render_template("barChart.html")
@app.route("/rose")
def roseChart():
return render_template("roseChart.html")
@app.route("/pie")
def pieChart():
return render_template("pieChart.html")
@app.route("/hist")
def histChart():
return render_template("histChart.html")
@app.route("/box")
def boxChart():
return render_template("boxChart.html")
@app.route("/sp")
def spChart():
return render_template("spChart.html")
@app.route("/sca")
def scatter_Chart():
return render_template("scatter.html")
@app.route("/Stacked")
def stacked_columns():
return render_template("Stacked_columns.html")
@app.route("/line")
def line_columns():
return render_template("lineChart.html")
@app.route("/mapChart")
def get_map_chart():
m = map_base()
return m.dump_options_with_quotes()
@app.route("/histChart")
def get_hist_chart():
w = hist_base()
return w.dump_options_with_quotes()
@app.route("/pieChart")
def get_pie_chart():
p = pie_base()
return p.dump_options_with_quotes()
@app.route("/roseChart")
def get_rose_chart():
r = rose_base()
return r.dump_options_with_quotes()
@app.route("/boxChart")
def get_box_chart():
r = box_base()
return r.dump_options_with_quotes()
@app.route("/spChart")
def get_sp_Chart():
r=spChart_base()
return r.dump_options_with_quotes()
@app.route("/scatter")
def get_Scatter_Chart():
r=Scatter_base()
return r.dump_options_with_quotes()
@app.route("/Stacked_columns")
def get_stacked__Chart():
r=stacked_columns_base()
return r.dump_options_with_quotes()
@app.route("/lineChart")
def get_line_Chart():
r=line_chart_base()
return r.dump_options_with_quotes()
@app.route("/barChart")
def get_bar_Chart():
r=bar_chart_base()
return r.dump_options_with_quotes()
if __name__ == "__main__":
app.run(host='localhost', port=778)#172.19.187.92
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Python
1
https://gitee.com/pu-zhuo/AutoView.git
git@gitee.com:pu-zhuo/AutoView.git
pu-zhuo
AutoView
AutoView
main

搜索帮助

0d507c66 1850385 C8b1a773 1850385