Skip to content

Latest commit

 

History

History
27 lines (22 loc) · 676 Bytes

geo_guangdong.md

File metadata and controls

27 lines (22 loc) · 676 Bytes

pyecharts 代码 / 效果

from pyecharts import options as opts
from pyecharts.charts import Geo
from pyecharts.faker import Faker
from pyecharts.globals import ChartType

c = (
    Geo()
    .add_schema(maptype="广东")
    .add(
        "geo",
        [list(z) for z in zip(Faker.guangdong_city, Faker.values())],
        type_=ChartType.HEATMAP,
    )
    .set_series_opts(label_opts=opts.LabelOpts(is_show=False))
    .set_global_opts(
        visualmap_opts=opts.VisualMapOpts(), title_opts=opts.TitleOpts(title="Geo-广东地图")
    )
    .render("geo_guangdong.html")
)
<iframe width="100%" height="800px" src="Geo/geo_guangdong.html"></iframe>