精华内容
下载资源
问答
  • 热力图

    2019-07-10 14:39:14
    HeatMap(热力图热力图主要通过颜色去表现数值的大小,必须要配合 visualMap 组件使用。直角坐标系上必须要使用两个类目轴。 import random from pyecharts import HeatMap x_axis = [ "12a", "1a", "2a", "3a...

    HeatMap(热力图)

    热力图主要通过颜色去表现数值的大小,必须要配合 visualMap 组件使用。直角坐标系上必须要使用两个类目轴。

    import random
    from pyecharts import HeatMap
    
    x_axis = [
        "12a", "1a", "2a", "3a", "4a", "5a", "6a", "7a", "8a", "9a", "10a", "11a",
        "12p", "1p", "2p", "3p", "4p", "5p", "6p", "7p", "8p", "9p", "10p", "11p"]
    y_axis = ["Saturday", "Friday", "Thursday", "Wednesday", "Tuesday", "Monday", "Sunday"]
    data = [[i, j, random.randint(0, 50)] for i in range(24) for j in range(7)]
    
    heatmap = HeatMap()
    heatmap.add("热力图直角坐标系", x_axis, y_axis, data,
                is_visualmap=True, visual_text_color="#000", visual_orient="horizontal",
                visual_pos="left", visual_bottom="20%")
    heatmap
    
    <div id="f8c7f3083e2f4ea6935340bcecf27797" style="width:800px;height:400px;"></div>
    
    import datetime
    import random
    from pyecharts import HeatMap
    
    begin, end = datetime.date(2017, 1, 1), datetime.date(2017, 12, 31)
    data = [[str(begin + datetime.timedelta(days=i)),
            random.randint(1000, 25000)] for i in range((end - begin).days + 1)]
    heatmap = HeatMap("日历热力图示例", "某人 2017 年微信步数情况", width=1000)
    heatmap.add("", data,
                is_calendar_heatmap=True,
                is_visualmap=True,
                visual_orient="horizontal", visual_pos="center", visual_top="70%", 
                visual_text_color='#000', visual_range_text=['', ''],
                visual_range=[1000, 25000],
                calendar_cell_size=['auto', 30],
                visual_split_number=3,  # 分段型中分割的段数,在设置为分段型时生效。默认分为 5 段。
                calendar_date_range="2017",
                is_piecewise=True,  # 是否将组件转换为分段型(默认为连续型),默认为 False
               )
    heatmap
    
    <div id="89d31bdf784d4b148aa0f697e2b4d22a" style="width:1000px;height:400px;"></div>
    
    展开全文
  • 一、python可视化——热力图

    万次阅读 多人点赞 2018-04-04 10:41:57
    热力图 1、利用热力图可以看数据表里多个特征两两的相似度。参考官方API参数及地址: seaborn.heatmap(data, vmin=None, vmax=None,cmap=None, center=None, robust=False, annot=None, fmt=’.2g’, annot_kws=...

    热力图

    1、利用热力图可以看数据表里多个特征两两的相似度。参考官方API参数及地址:

    seaborn.heatmap(data, vmin=None, vmax=None,cmap=None, center=None, robust=False, annot=None, fmt=’.2g’, annot_kws=None,linewidths=0, linecolor=’white’, cbar=True, cbar_kws=None, cbar_ax=None,square=False, xticklabels=’auto’, yticklabels=’auto’, mask=None, ax=None,**kwargs)

    (1)热力图输入数据参数:

    data:矩阵数据集,可以是numpy的数组(array),也可以是pandas的DataFrame。如果是DataFrame,则df的index/column信息会分别对应到heatmap的columns和rows,即df.index是热力图的行标,df.columns是热力图的列标

    (2)热力图矩阵块颜色参数:

    vmax,vmin:分别是热力图的颜色取值最大和最小范围,默认是根据data数据表里的取值确定
    cmap:从数字到色彩空间的映射,取值是matplotlib包里的colormap名称或颜色对象,或者表示颜色的列表;改参数默认值:根据center参数设定
    center:数据表取值有差异时,设置热力图的色彩中心对齐值;通过设置center值,可以调整生成的图像颜色的整体深浅;设置center数据时,如果有数据溢出,则手动设置的vmax、vmin会自动改变
    robust:默认取值False;如果是False,且没设定vmin和vmax的值,热力图的颜色映射范围根据具有鲁棒性的分位数设定,而不是用极值设定

    (3)热力图矩阵块注释参数:

    annot(annotate的缩写):默认取值False;如果是True,在热力图每个方格写入数据;如果是矩阵,在热力图每个方格写入该矩阵对应位置数据
    fmt:字符串格式代码,矩阵上标识数字的数据格式,比如保留小数点后几位数字
    annot_kws:默认取值False;如果是True,设置热力图矩阵上数字的大小颜色字体,matplotlib包text类下的字体设置;官方文档:

    (4)热力图矩阵块之间间隔及间隔线参数:

    linewidths:定义热力图里“表示两两特征关系的矩阵小块”之间的间隔大小
    linecolor:切分热力图上每个矩阵小块的线的颜色,默认值是’white’

    (5)热力图颜色刻度条参数:

    cbar:是否在热力图侧边绘制颜色刻度条,默认值是True
    cbar_kws:热力图侧边绘制颜色刻度条时,相关字体设置,默认值是None
    cbar_ax:热力图侧边绘制颜色刻度条时,刻度条位置设置,默认值是None

    (6)square:设置热力图矩阵小块形状,默认值是False

    xticklabels, yticklabels:xticklabels控制每列标签名的输出;yticklabels控制每行标签名的输出。默认值是auto。如果是True,则以DataFrame的列名作为标签名。如果是False,则不添加行标签名。如果是列表,则标签名改为列表中给的内容。如果是整数K,则在图上每隔K个标签进行一次标注。 如果是auto,则自动选择标签的标注间距,将标签名不重叠的部分(或全部)输出
    mask:控制某个矩阵块是否显示出来。默认值是None。如果是布尔型的DataFrame,则将DataFrame里True的位置用白色覆盖掉
    ax:设置作图的坐标轴,一般画多个子图时需要修改不同的子图的该值
    **kwargs:All other keyword arguments are passed to ax.pcolormesh

     

    热力图矩阵块颜色参数

    #cmap(颜色)
    
    import matplotlib.pyplot as plt
    import seaborn as sns
    % matplotlib inline
    
    f, (ax1,ax2) = plt.subplots(figsize = (6,4),nrows=2)
    
    # cmap用cubehelix map颜色
    cmap = sns.cubehelix_palette(start = 1.5, rot = 3, gamma=0.8, as_cmap = True)
    pt = df.corr()   # pt为数据框或者是协方差矩阵
    sns.heatmap(pt, linewidths = 0.05, ax = ax1, vmax=900, vmin=0, cmap=cmap)
    ax1.set_title('cubehelix map')
    ax1.set_xlabel('')
    ax1.set_xticklabels([]) #设置x轴图例为空值
    ax1.set_ylabel('kind')
    
    # cmap用matplotlib colormap
    sns.heatmap(pt, linewidths = 0.05, ax = ax2, vmax=900, vmin=0, cmap='rainbow') 
    # rainbow为 matplotlib 的colormap名称
    ax2.set_title('matplotlib colormap')
    ax2.set_xlabel('region')
    ax2.set_ylabel('kind')

    这里写图片描述

    #center的用法(颜色)
    
    f, (ax1,ax2) = plt.subplots(figsize = (6, 4),nrows=2)
    
    cmap = sns.cubehelix_palette(start = 1.5, rot = 3, gamma=0.8, as_cmap = True)
    sns.heatmap(pt, linewidths = 0.05, ax = ax1, cmap=cmap, center=None )
    ax1.set_title('center=None')
    ax1.set_xlabel('')
    ax1.set_xticklabels([]) #设置x轴图例为空值
    ax1.set_ylabel('kind')
    
    # 当center设置小于数据的均值时,生成的图片颜色要向0值代表的颜色一段偏移
    sns.heatmap(pt, linewidths = 0.05, ax = ax2, cmap=cmap, center=200)   
    ax2.set_title('center=3000')
    ax2.set_xlabel('region')
    ax2.set_ylabel('kind')

    这里写图片描述

    #robust的用法(颜色)
    
    f, (ax1,ax2) = plt.subplots(figsize = (6,4),nrows=2)
    
    cmap = sns.cubehelix_palette(start = 1.5, rot = 3, gamma=0.8, as_cmap = True)
    
    sns.heatmap(pt, linewidths = 0.05, ax = ax1, cmap=cmap, center=None, robust=False )
    ax1.set_title('robust=False')
    ax1.set_xlabel('')
    ax1.set_xticklabels([]) #设置x轴图例为空值
    ax1.set_ylabel('kind')
    
    sns.heatmap(pt, linewidths = 0.05, ax = ax2, cmap=cmap, center=None, robust=True ) 
    ax2.set_title('robust=True')
    ax2.set_xlabel('region')
    ax2.set_ylabel('kind')

    这里写图片描述

    热力图矩阵块注释参数

    #annot(矩阵上数字),annot_kws(矩阵上数字的大小颜色字体)matplotlib包text类下的字体设置
    
    import numpy as np
    np.random.seed(20180316)
    x = np.random.randn(4, 4)
    
    f, (ax1, ax2) = plt.subplots(figsize=(6,6),nrows=2)
    
    sns.heatmap(x, annot=True, ax=ax1)
    
    sns.heatmap(x, annot=True, ax=ax2, annot_kws={'size':9,'weight':'bold', 'color':'blue'})
    # Keyword arguments for ax.text when annot is True.  http://stackoverflow.com/questions/35024475/seaborn-heatmap-key-words

    这里写图片描述

    #fmt(字符串格式代码,矩阵上标识数字的数据格式,比如保留小数点后几位数字)
    
    import numpy as np
    np.random.seed(0)
    x = np.random.randn(4,4)
    
    f, (ax1, ax2) = plt.subplots(figsize=(6,6),nrows=2)
    
    sns.heatmap(x, annot=True, ax=ax1)
    
    sns.heatmap(x, annot=True, fmt='.1f', ax=ax2)

    这里写图片描述

    热力图矩阵块之间间隔及间隔线参数

    #linewidths(矩阵小块的间隔),linecolor(切分热力图矩阵小块的线的颜色)
    
    import matplotlib.pyplot as plt
    f, ax = plt.subplots(figsize = (6,4))
    cmap = sns.cubehelix_palette(start = 1, rot = 3, gamma=0.8, as_cmap = True)   
    sns.heatmap(pt, cmap = cmap, linewidths = 0.05, linecolor= 'red', ax = ax)   
    ax.set_title('Amounts per kind and region')
    ax.set_xlabel('region')
    ax.set_ylabel('kind')

    这里写图片描述

    #xticklabels,yticklabels横轴和纵轴的标签名输出
    
    import matplotlib.pyplot as plt
    f, (ax1,ax2) = plt.subplots(figsize = (5,5),nrows=2)
    
    cmap = sns.cubehelix_palette(start = 1.5, rot = 3, gamma=0.8, as_cmap = True)
    
    p1 = sns.heatmap(pt, ax=ax1, cmap=cmap, center=None, xticklabels=False)
    ax1.set_title('xticklabels=None',fontsize=8)
    
    p2 = sns.heatmap(pt, ax=ax2, cmap=cmap, center=None, xticklabels=2, yticklabels=list(range(5))) 
    ax2.set_title('xticklabels=2, yticklabels is a list',fontsize=8)
    ax2.set_xlabel('region')

    这里写图片描述

    #mask对某些矩阵块的显示进行覆盖
    
    f, (ax1,ax2) = plt.subplots(figsize = (5,5),nrows=2)
    
    cmap = sns.cubehelix_palette(start = 1.5, rot = 3, gamma=0.8, as_cmap = True)
    
    p1 = sns.heatmap(pt, ax=ax1, cmap=cmap, xticklabels=False, mask=None)
    ax1.set_title('mask=None')
    ax1.set_ylabel('kind')
    
    p2 = sns.heatmap(pt, ax=ax2, cmap=cmap, xticklabels=True, mask=(pt<800))   
    #mask对pt进行布尔型转化,结果为True的位置用白色覆盖
    ax2.set_title('mask: boolean DataFrame')
    ax2.set_xlabel('region')
    ax2.set_ylabel('kind')

    这里写图片描述

    用mask实现:突出显示某些数据

    f,(ax1,ax2) = plt.subplots(figsize=(4,6),nrows=2)
    x = np.array([[1,2,3],[2,0,1],[-1,-2,0]])
    sns.heatmap(x, annot=True, ax=ax1)
    sns.heatmap(x, mask=x < 1, ax=ax2, annot=True, annot_kws={"weight": "bold"})   #把小于1的区域覆盖掉

    这里写图片描述

    本文为转载,原地址:https://blog.csdn.net/cymy001/article/details/79576019。点击打开链接

    展开全文
  • Python如如何何绘绘制制日日历历图图和和热热力力图图 这篇文章主要介绍了Python如何绘制日历图和热力图帮助大家更好的理解和学习Python感兴趣的朋友可以了 解下 文以2019年全国各城市的空气质量观测数据为例利用...
  • 热力图插件

    2018-03-09 10:38:39
    openlayer热力图插件openlayer热力图插件openlayer热力图插件
  • 最简单的地图热力图,用的是百度的api,所以取经纬度的时候最好也用百度地图。这里已经填好百度api的key了,但还是建议大家注册使用自己的key,因为有每日额度,超过访问次数了就不可用了。效果展示:下面是完整代码...

    最简单的地图热力图,用的是百度的api,所以取经纬度的时候最好也用百度地图。

    这里已经填好百度api的key了,但还是建议大家注册使用自己的key,因为有每日额度,超过访问次数了就不可用了。

    效果展示:

    cd8254f022b6e8677aaa47c8bac5b1b5.png

    下面是完整代码,注释已经标得很清楚了,直接保存为html文件用浏览器打开就可以了。

    XXXXX

    ul,li{list-style: none;margin:0;padding:0;float:left;}

    html{height:100%}

    body{height:100%;margin:0px;padding:0px;font-family:"微软雅黑";}

    #allmap{height:100%;width:100%;}

    // 百度地图API功能

    var map = new BMap.Map("allmap");

    //设置打开后的中心位置,这里设置的是北京

    var point = new BMap.Point(116.512885,39.847469);

    //设置打开后的缩放大小,这里设置的大致为中国版图的大小

    map.centerAndZoom(point, 5);

    // 编写自定义函数,创建标注

    function addMarker(point){

    var marker = new BMap.Marker(point);

    map.addOverlay(marker);

    }

    //lat是纬度,lng是经度,count是对应的数值大小

    //下列的经纬度基本覆盖了中国各个省份及重要城市

    var res = [{"count": 61, "lat": 30.5984667364009, "lng":114.311581554732},

    {"count": 18, "lat": 30.9306892270182, "lng":113.922510077336},

    {"count": 70, "lat": 30.4593588576181, "lng":114.878490484107},

    {"count": 2, "lat": 31.6965167723283, "lng":113.389450018221},

    {"count": 47, "lat": 30.3408421077429, "lng":112.245522629261},

    {"count": 59, "lat": 32.0147968046692, "lng":112.128537201002},

    {"count": 86, "lat": 30.2052078489415, "lng":115.045532908943},

    {"count": 33, "lat": 30.6974464844923, "lng":111.292549210354},

    {"count": 24, "lat": 31.0417325755696, "lng":112.20639298023},

    {"count": 68, "lat": 30.3965721733169, "lng":114.90160738827},

    {"count": 57, "lat": 29.8470559476464, "lng":114.328519090268},

    {"count": 41, "lat": 32.6350618584011, "lng":110.804529560695},

    {"count": 76, "lat": 30.3335877511463, "lng":113.449609358563},

    {"count": 4, "lat": 30.6696218300994, "lng":113.172409166328},

    {"count": 10, "lat": 30.277939575301, "lng":109.494592618575},

    {"count": 38, "lat": 30.4083579324189, "lng":112.905474090816},

    {"count": 76, "lat": 31.7504960112464, "lng":110.682524850399},

    {"count": 90, "lat": 30.5516000646583, "lng":114.348440736587},

    {"count": 84, "lat": 22.5484566379841, "lng":114.064551836587},

    {"count": 57, "lat": 23.135336306695, "lng":113.271431344459},

    {"count": 59, "lat": 22.2765646542492, "lng":113.582554786549},

    {"count": 76, "lat": 23.0277587507889, "lng":113.128512195497},

    {"count": 58, "lat": 23.0273084116433, "lng":113.758420457876},

    {"count": 52, "lat": 22.5223146707905, "lng":113.399422362631},

    {"count": 36, "lat": 23.1163588547255, "lng":114.423558016581},

    {"count": 99, "lat": 23.3590917177251, "lng":116.688528640548},

    {"count": 99, "lat": 21.276723439012, "lng":110.365554413928},

    {"count": 30, "lat": 23.0528887711256, "lng":112.47148894063},

    {"count": 78, "lat": 22.584603880965, "lng":113.08855619524},

    {"count": 96, "lat": 21.8643397261389, "lng":111.988489291812},

    {"count": 70, "lat": 24.2941775322062, "lng":116.129537376122},

    {"count": 4, "lat": 23.688230292088, "lng":113.062468325272},

    {"count": 23, "lat": 23.5557404882755, "lng":116.378512180338},

    {"count": 60, "lat": 21.669064031332, "lng":110.931542579969},

    {"count": 40, "lat": 24.815881278583, "lng":113.603527345622},

    {"count": 7, "lat": 22.7912630365467, "lng":115.38155260365},

    {"count": 63, "lat": 23.6626231926158, "lng":116.629470173628},

    {"count": 22, "lat": 23.7496843709597, "lng":114.707446272906},

    {"count": 77, "lat": 28.0010854044722, "lng":120.706476890355},

    {"count": 70, "lat": 30.2530829816934, "lng":120.215511803721},

    {"count": 96, "lat": 29.866033045866, "lng":121.628572494341},

    {"count": 64, "lat": 28.6621940559961, "lng":121.427434704279},

    {"count": 62, "lat": 29.0846393855136, "lng":119.653436190529},

    {"count": 33, "lat": 30.7509748309201, "lng":120.76355182586},

    {"count": 98, "lat": 30.0363693113069, "lng":120.585478478853},

    {"count": 17, "lat": 28.4732781805634, "lng":119.929573058441},

    {"count": 37, "lat": 28.975545802265, "lng":118.866596740355},

    {"count": 80, "lat": 30.8989639372941, "lng":120.094516609157},

    {"count": 76, "lat": 29.9909116801603, "lng":122.21355631852},

    {"count": 62, "lat": 32.153014547531, "lng":114.097482833045},

    {"count": 75, "lat": 32.9965622046514, "lng":112.534501313513},

    {"count": 2, "lat": 34.7534388504544, "lng":113.631419207339},

    {"count": 24, "lat": 33.0178424167436, "lng":114.028470781732},

    {"count": 84, "lat": 34.4202016658586, "lng":115.662449338262},

    {"count": 20, "lat": 33.6318288757022, "lng":114.703482514823},

    {"count": 45, "lat": 33.772050748691, "lng":113.199528560521},

    {"count": 14, "lat": 35.3096399303368, "lng":113.933600467332},

    {"count": 19, "lat": 36.1059409840149, "lng":114.399500421774},

    {"count": 73, "lat": 34.0414316116187, "lng":113.858475536855},

    {"count": 90, "lat": 33.5877107071022, "lng":114.023420777647},

    {"count": 81, "lat": 34.6242627792194, "lng":112.459421298311},

    {"count": 26, "lat": 34.8028858112117, "lng":114.314592584971},

    {"count": 26, "lat": 35.2209632540389, "lng":113.248547834573},

    {"count": 63, "lat": 35.7523574114, "lng":114.303593642476},

    {"count": 87, "lat": 34.7783272494599, "lng":111.206533223874},

    {"count": 26, "lat": 35.7675930289062, "lng":115.035597470342},

    {"count": 29, "lat": 35.0729072268465, "lng":112.608580706207},

    {"count": 41, "lat": 34.7717129219314, "lng":113.759384084863},

    {"count": 19, "lat": 28.2348893999436, "lng":112.945473195352},

    {"count": 32, "lat": 29.3631782939259, "lng":113.135489424221},

    {"count": 4, "lat": 27.2452702728085, "lng":111.474432885931},

    {"count": 35, "lat": 29.0377499994068, "lng":111.705452179958},

    {"count": 70, "lat": 27.7032085969915, "lng":112.001503492884},

    {"count": 87, "lat": 27.8335676390164, "lng":113.140470797764},

    {"count": 85, "lat": 26.8995761391891, "lng":112.578447213259},

    {"count": 67, "lat": 28.5597111784898, "lng":112.36151595471},

    {"count": 19, "lat": 26.4258641179, "lng":111.619455057922},

    {"count": 7, "lat": 27.5751609029785, "lng":110.008514265372},

    {"count": 99, "lat": 25.7766832736018, "lng":113.021460499094},

    {"count": 30, "lat": 27.8357022271355, "lng":112.950464180764},

    {"count": 99, "lat": 28.3173691047011, "lng":109.745576649466},

    {"count": 71, "lat": 29.1228155625518, "lng":110.485532546954},

    {"count": 12, "lat": 28.1182699980093, "lng":112.989602543346},

    {"count": 21, "lat": 31.8265778336868, "lng":117.233442664976},

    {"count": 65, "lat": 32.8960609948522, "lng":115.820436124913},

    {"count": 59, "lat": 32.9215237043508, "lng":117.395513328136},

    {"count": 42, "lat": 33.8506426957888, "lng":115.784463211274},

    {"count": 13, "lat": 30.530956568043, "lng":117.063603904918},

    {"count": 94, "lat": 31.7414508153225, "lng":116.526409664185},

    {"count": 39, "lat": 31.6762655976091, "lng":118.513579579431},

    {"count": 40, "lat": 31.3585366557992, "lng":118.439431376535},

    {"count": 11, "lat": 33.6520953264521, "lng":116.970543945612},

    {"count": 100, "lat": 33.9616563002763, "lng":116.804537267029},

    {"count": 92, "lat": 30.9512332399133, "lng":117.818476794457},

    {"count": 49, "lat": 32.6318473990533, "lng":117.006388850716},

    {"count": 99, "lat": 30.6708837907645, "lng":117.498420961596},

    {"count": 28, "lat": 32.2612708720408, "lng":118.339406135965},

    {"count": 60, "lat": 29.7218897865916, "lng":118.345437253147},

    {"count": 15, "lat": 30.9466015452929, "lng":118.765534242767},

    {"count": 95, "lat": 28.6894552950607, "lng":115.864589442316},

    {"count": 26, "lat": 29.7113405590793, "lng":116.00753491163},

    {"count": 52, "lat": 27.8235786977885, "lng":114.923534651396},

    {"count": 50, "lat": 28.4606259218517, "lng":117.949459603122},

    {"count": 69, "lat": 27.8208564218482, "lng":114.423563675906},

    {"count": 75, "lat": 25.8351761034976, "lng":114.940503372982},

    {"count": 57, "lat": 27.9548922534195, "lng":116.364538768643},

    {"count": 51, "lat": 27.6283927093972, "lng":113.861496433754},

    {"count": 11, "lat": 27.1197268260704, "lng":115.000510720012},

    {"count": 48, "lat": 28.2657870631914, "lng":117.075575427027},

    {"count": 45, "lat": 29.2742477110409, "lng":117.184576446385},

    {"count": 71, "lat": 30.8136216367076, "lng":108.415558370502},

    {"count": 56, "lat": 30.9366112719747, "lng":108.703447500001},

    {"count": 3, "lat": 29.5079277155528, "lng":106.51755873943},

    {"count": 40, "lat": 29.6128323140802, "lng":106.580415062384},

    {"count": 18, "lat": 29.5590901829938, "lng":106.57544006681},

    {"count": 79, "lat": 31.1666441131934, "lng":108.39949765612},

    {"count": 33, "lat": 30.3332939685, "lng":107.339565874718},

    {"count": 52, "lat": 30.3052683893565, "lng":108.044537533855},

    {"count": 72, "lat": 29.9781812395342, "lng":106.282541087579},

    {"count": 51, "lat": 29.7089458384214, "lng":106.554012965149},

    {"count": 93, "lat": 29.0341137483112, "lng":106.657484195451},

    {"count": 22, "lat": 30.197314239664, "lng":105.847399036165},

    {"count": 36, "lat": 31.0246017665491, "lng":109.470472756309},

    {"count": 38, "lat": 29.7239273430066, "lng":106.637559060602},

    {"count": 51, "lat": 30.0061086978689, "lng":108.120414166383},

    {"count": 80, "lat": 29.8635200673231, "lng":107.087531070068},

    {"count": 72, "lat": 31.4048800098582, "lng":109.576402558996},

    {"count": 65, "lat": 29.869412789214, "lng":107.737480618198},

    {"count": 12, "lat": 29.2229269414888, "lng":106.29811321359},

    {"count": 87, "lat": 31.0805188117359, "lng":109.88554550703},

    {"count": 80, "lat": 29.5983466073163, "lng":106.233474562674},

    {"count": 87, "lat": 29.5026830988349, "lng":106.668429778595},

    {"count": 40, "lat": 29.4113073966899, "lng":105.601419799279},

    {"count": 2, "lat": 29.490107128556, "lng":106.488533590107},

    {"count": 45, "lat": 29.8505087787222, "lng":106.063449494109},

    {"count": 4, "lat": 30.6605532550234, "lng":107.77609725763},

    {"count": 61, "lat": 29.2958843744649, "lng":106.265597608378},

    {"count": 87, "lat": 29.5479422056355, "lng":106.314882870675},

    {"count": 72, "lat": 29.362046335949, "lng":105.933499361451},

    {"count": 66, "lat": 29.7092781979787, "lng":107.396419797541},

    {"count": 92, "lat": 29.4084747397704, "lng":106.547454256962},

    {"count": 63, "lat": 31.9533907462925, "lng":108.671611642558},

    {"count": 37, "lat": 29.5388125676601, "lng":108.777591198349},

    {"count": 23, "lat": 29.5471925165411, "lng":106.464465110925},

    {"count": 43, "lat": 29.2994622904425, "lng":108.172578035882},

    {"count": 99, "lat": 29.3320268707489, "lng":107.766425189517},

    {"count": 48, "lat": 28.453447864286, "lng":109.013573899809},

    {"count": 98, "lat": 28.8470402586741, "lng":108.774586007097},

    {"count": 19, "lat": 28.9678347896873, "lng":106.931558284422},

    {"count": 91, "lat": 31.3035640744417, "lng":120.592412229593},

    {"count": 74, "lat": 32.0646528856184, "lng":118.802421721245},

    {"count": 90, "lat": 34.212666550113, "lng":117.290575434394},

    {"count": 69, "lat": 33.6162953010331, "lng":119.021483670706},

    {"count": 92, "lat": 31.4988097326857, "lng":120.318583288106},

    {"count": 51, "lat": 32.4606750493083, "lng":119.929566337854},

    {"count": 37, "lat": 31.9865494312008, "lng":120.901591738661},

    {"count": 58, "lat": 31.8157956533278, "lng":119.981484713278},

    {"count": 77, "lat": 34.6022495252672, "lng":119.228621333166},

    {"count": 71, "lat": 32.4006769360903, "lng":119.419418908229},

    {"count": 78, "lat": 33.3551009176261, "lng":120.167544265761},

    {"count": 96, "lat": 33.96774971569, "lng":118.281574035708},

    {"count": 56, "lat": 32.1947159205237, "lng":119.430489445673},

    {"count": 8, "lat": 36.0722274966632, "lng":120.389455191146},

    {"count": 44, "lat": 36.6565542017872, "lng":117.12639941261},

    {"count": 96, "lat": 35.4201773945296, "lng":116.593612348539},

    {"count": 98, "lat": 35.1106712423651, "lng":118.363533005013},

    {"count": 56, "lat": 37.4700383837305, "lng":121.454415417301},

    {"count": 93, "lat": 37.5164305480148, "lng":122.127540978313},

    {"count": 14, "lat": 36.7126515512675, "lng":119.168377911428},

    {"count": 51, "lat": 37.4413084545762, "lng":116.365556743974},

    {"count": 98, "lat": 36.2058580448846, "lng":117.094494834795},

    {"count": 39, "lat": 36.4627581876941, "lng":115.991587848304},

    {"count": 44, "lat": 34.8159940484351, "lng":117.330541944838},

    {"count": 77, "lat": 36.8190856833218, "lng":118.061452534898},

    {"count": 59, "lat": 35.4228389984376, "lng":119.533415404565},

    {"count": 43, "lat": 35.2394074247655, "lng":115.487545033433},

    {"count": 63, "lat": 37.3881961960769, "lng":117.977404017146},

    {"count": 89, "lat": 30.6558218784164, "lng":104.081533510424},

    {"count": 52, "lat": 30.843782508337, "lng":106.117502614872},

    {"count": 23, "lat": 30.4617461106789, "lng":106.639552682334},

    {"count": 40, "lat": 31.2143077239274, "lng":107.474593858975},

    {"count": 9, "lat": 31.8728885859565, "lng":106.751585303164},

    {"count": 47, "lat": 31.4736630487458, "lng":104.685561860761},

    {"count": 43, "lat": 29.5858865383204, "lng":105.064588024997},

    {"count": 97, "lat": 30.0552788435183, "lng":101.96854674579},

    {"count": 31, "lat": 28.8776683036072, "lng":105.448524069326},

    {"count": 99, "lat": 31.1331150036567, "lng":104.404419364964},

    {"count": 41, "lat": 26.588033173333, "lng":101.725541170914},

    {"count": 100, "lat": 28.7580070285518, "lng":104.649403704869},

    {"count": 49, "lat": 29.3455849213275, "lng":104.784448846717},

    {"count": 67, "lat": 27.8877523003697, "lng":102.27350268097},

    {"count": 11, "lat": 32.4416163053154, "lng":105.850423181664},

    {"count": 56, "lat": 30.016792545706, "lng":103.049542623604},

    {"count": 77, "lat": 30.5390976711091, "lng":105.599421530644},

    {"count": 83, "lat": 30.082526119421, "lng":103.856563315794},

    {"count": 9, "lat": 29.5579407174581, "lng":103.772537603634},

    {"count": 10, "lat": 30.1349565592531, "lng":104.634435341644},

    {"count": 41, "lat": 31.9055115772665, "lng":102.23141546175},

    {"count": 37, "lat": 39.9109245472995, "lng":116.413383697123},

    {"count": 29, "lat": 39.9263745230798, "lng":116.449558729501},

    {"count": 33, "lat": 39.9654898411007, "lng":116.305434054497},

    {"count": 46, "lat": 39.9181236058414, "lng":116.372513581166},

    {"count": 81, "lat": 39.7325552365544, "lng":116.348625212231},

    {"count": 43, "lat": 39.9109245472995, "lng":116.413383697123},

    {"count": 94, "lat": 39.8649371975573, "lng":116.292401887311},

    {"count": 72, "lat": 40.2264133715942, "lng":116.23761791731},

    {"count": 83, "lat": 39.9551864560804, "lng":116.725840224692},

    {"count": 10, "lat": 39.9113538087782, "lng":116.229612667758},

    {"count": 49, "lat": 39.7543258397733, "lng":116.149443751842},

    {"count": 95, "lat": 40.1363507622307, "lng":116.66142426369},

    {"count": 33, "lat": 39.9348272723959, "lng":116.422400977662},

    {"count": 28, "lat": 40.3226184042657, "lng":116.638385871429},

    {"count": 40, "lat": 39.946146720034, "lng":116.107603555765},

    {"count": 72, "lat": 40.4621689737542, "lng":115.981631569015},

    {"count": 4, "lat": 39.9109245472995, "lng":116.413383697123},

    {"count": 88, "lat": 45.7677178653451, "lng":126.604654038801},

    {"count": 24, "lat": 45.8088258279521, "lng":126.541615090316},

    {"count": 33, "lat": 46.6600321798244, "lng":126.975356875301},

    {"count": 55, "lat": 46.653185895886, "lng":131.16534168078},

    {"count": 98, "lat": 45.3008723178238, "lng":130.975618658766},

    {"count": 35, "lat": 47.3599771860153, "lng":123.924570868415},

    {"count": 27, "lat": 46.8056899908577, "lng":130.327359092573},

    {"count": 5, "lat": 46.5936331767217, "lng":125.10865763402},

    {"count": 77, "lat": 44.5562457089863, "lng":129.639539778346},

    {"count": 6, "lat": 45.7763003215478, "lng":131.011544591027},

    {"count": 49, "lat": 47.356056157685, "lng":130.304432898669},

    {"count": 6, "lat": 50.4200259550278, "lng":124.15292785448},

    {"count": 48, "lat": 50.2512723117501, "lng":127.535489886218},

    {"count": 90, "lat": 31.235929042252, "lng":121.480538860176},

    {"count": 16, "lat": 31.235929042252, "lng":121.480538860176},

    {"count": 3, "lat": 31.2273482924363, "lng":121.550454606831},

    {"count": 56, "lat": 31.4102794734761, "lng":121.496563013524},

    {"count": 15, "lat": 31.1945567728227, "lng":121.443396352763},

    {"count": 20, "lat": 31.2338449304016, "lng":121.453431772768},

    {"count": 57, "lat": 31.0371351764644, "lng":121.234479596241},

    {"count": 45, "lat": 31.1188425800874, "lng":121.38861193361},

    {"count": 74, "lat": 31.2268479682254, "lng":121.43045437545},

    {"count": 5, "lat": 30.9237201102853, "lng":121.480503736431},

    {"count": 87, "lat": 31.2697466989313, "lng":121.511586454534},

    {"count": 28, "lat": 31.265524144657, "lng":121.532519937325},

    {"count": 32, "lat": 31.2549733682795, "lng":121.403569349165},

    {"count": 46, "lat": 31.3801553396772, "lng":121.272595058352},

    {"count": 58, "lat": 31.2372471520636, "lng":121.491585592524},

    {"count": 40, "lat": 31.1554543179807, "lng":121.130553104672},

    {"count": 43, "lat": 30.7478523765703, "lng":121.348480045121},

    {"count": 13, "lat": 31.628569984404, "lng":121.403556862718},

    {"count": 27, "lat": 31.235929042252, "lng":121.480538860176},

    {"count": 66, "lat": 26.0586607377664, "lng":119.35038995226},

    {"count": 48, "lat": 26.080429420698, "lng":119.30346983854},

    {"count": 82, "lat": 25.4598654559227, "lng":119.014520978126},

    {"count": 77, "lat": 24.8799523304983, "lng":118.682446266804},

    {"count": 68, "lat": 24.4854066051763, "lng":118.096435499766},

    {"count": 84, "lat": 24.5189297911708, "lng":117.653576452987},

    {"count": 7, "lat": 26.6722417114085, "lng":119.554510745428},

    {"count": 36, "lat": 26.6477728742032, "lng":118.184369548142},

    {"count": 88, "lat": 26.2697365159918, "lng":117.645521167821},

    {"count": 53, "lat": 25.0812198448716, "lng":117.023447566775},

    {"count": 14, "lat": 26.106339415901, "lng":119.302447477039},

    {"count": 95, "lat": 34.2758080060236, "lng":108.960393148751},

    {"count": 29, "lat": 34.3472688166239, "lng":108.946465550632},

    {"count": 69, "lat": 32.6905127705737, "lng":109.035601082657},

    {"count": 54, "lat": 33.0737999078337, "lng":107.029430209264},

    {"count": 24, "lat": 34.3354762933685, "lng":108.715422451433},

    {"count": 53, "lat": 34.3689156428699, "lng":107.24457536704},

    {"count": 32, "lat": 34.5057155167525, "lng":109.516589605258},

    {"count": 29, "lat": 34.9026370805029, "lng":108.952404248359},

    {"count": 59, "lat": 33.8786338522077, "lng":109.924417881364},

    {"count": 61, "lat": 36.5911110352177, "lng":109.496581916126},

    {"count": 94, "lat": 38.290883835484, "lng":109.741616033813},

    {"count": 16, "lat": 35.4820867873131, "lng":110.449552640117},

    {"count": 48, "lat": 34.2459430118156, "lng":108.079533001268},

    {"count": 93, "lat": 39.1534851447047, "lng":117.203592781355},

    {"count": 93, "lat": 38.0520971098468, "lng":114.469021632649},

    {"count": 9, "lat": 38.310215141107, "lng":116.84558075595},

    {"count": 15, "lat": 36.631262731204, "lng":114.545628228235},

    {"count": 72, "lat": 37.076685950966, "lng":114.511462256129},

    {"count": 86, "lat": 39.6365837241473, "lng":118.186459472039},

    {"count": 67, "lat": 38.8799877684553, "lng":115.471463837685},

    {"count": 21, "lat": 39.5433666627585, "lng":116.690581733425},

    {"count": 35, "lat": 40.7732372026915, "lng":114.892572231451},

    {"count": 9, "lat": 37.7451914080774, "lng":115.675406137616},

    {"count": 32, "lat": 40.957856012338, "lng":117.969397509966},

    {"count": 1, "lat": 39.9417481023779, "lng":119.608530633343},

    {"count": 40, "lat": 31.6554050548164, "lng":119.747463821144},

    {"count": 96, "lat": 22.8226066011871, "lng":108.373450825818},

    {"count": 19, "lat": 21.4868364957694, "lng":109.126533212566},

    {"count": 36, "lat": 25.2428857248726, "lng":110.203545374579},

    {"count": 47, "lat": 24.3319613868524, "lng":109.434421946345},

    {"count": 80, "lat": 21.6930052899694, "lng":108.360418838298},

    {"count": 64, "lat": 24.6989117312728, "lng":108.091499944986},

    {"count": 1, "lat": 22.6598305099531, "lng":110.188453123372},

    {"count": 35, "lat": 21.9865935394842, "lng":108.660580168422},

    {"count": 1, "lat": 23.1174483820375, "lng":109.605520310333},

    {"count": 19, "lat": 23.4827452811351, "lng":111.28551681182},

    {"count": 13, "lat": 24.4094509028654, "lng":111.573526314162},

    {"count": 68, "lat": 23.9081859342959, "lng":106.624589325653},

    {"count": 85, "lat": 23.7565467626072, "lng":109.2274581959},

    {"count": 84, "lat": 24.917734785759, "lng":102.474046421598},

    {"count": 55, "lat": 24.873998150044, "lng":102.852448365004},

    {"count": 79, "lat": 22.0136012547641, "lng":100.803446824556},

    {"count": 66, "lat": 24.3577109424462, "lng":102.55356029311},

    {"count": 21, "lat": 25.6121284181925, "lng":100.274582840483},

    {"count": 24, "lat": 25.4964069315436, "lng":103.802434827946},

    {"count": 11, "lat": 27.3440838602468, "lng":103.723511771968},

    {"count": 14, "lat": 25.1390387932659, "lng":99.1772732858178},

    {"count": 26, "lat": 26.8606574380648, "lng":100.232464529034},

    {"count": 65, "lat": 23.3699962476054, "lng":103.381549052579},

    {"count": 47, "lat": 24.4380107027581, "lng":98.5913593561141},

    {"count": 65, "lat": 22.8309791860102, "lng":100.972569814727},

    {"count": 55, "lat": 25.0517735653403, "lng":101.534412480502},

    {"count": 19, "lat": 23.8904685562785, "lng":100.095440420148},

    {"count": 59, "lat": 23.4059942936117, "lng":104.222568991094},

    {"count": 10, "lat": 25.0515622673448, "lng":102.716416075232},

    {"count": 51, "lat": 36.2921024798988, "lng":100.626621144459},

    {"count": 82, "lat": 18.2587362917478, "lng":109.518556701399},

    {"count": 27, "lat": 20.0440494392567, "lng":110.325525471264},

    {"count": 94, "lat": 18.7333772333257, "lng":110.402780194249},

    {"count": 0, "lat": 19.5271461100441, "lng":109.587455835686},

    {"count": 36, "lat": 19.7443486716463, "lng":110.013510910109},

    {"count": 7, "lat": 19.2642540199176, "lng":110.48054452595},

    {"count": 14, "lat": 19.919474770278, "lng":109.697443014833},

    {"count": 100, "lat": 18.5123315956988, "lng":110.044464092547},

    {"count": 39, "lat": 19.3039978766842, "lng":109.062464087343},

    {"count": 64, "lat": 19.1011047312886, "lng":108.658566526791},

    {"count": 78, "lat": 19.6871199479101, "lng":110.365533483409},

    {"count": 97, "lat": 19.5935749727566, "lng":110.71832401809},

    {"count": 52, "lat": 18.8527220411434, "lng":109.333657041052},

    {"count": 51, "lat": 19.0391637891806, "lng":109.84451062847},

    {"count": 63, "lat": 18.7558714938548, "lng":109.180507988945},

    {"count": 33, "lat": 38.9762854681468, "lng":111.009670739159},

    {"count": 61, "lat": 37.6928394097597, "lng":112.759594755659},

    {"count": 0, "lat": 35.0327069129092, "lng":111.013389454479},

    {"count": 2, "lat": 37.8769890288477, "lng":112.556391491672},

    {"count": 80, "lat": 40.0824687161612, "lng":113.306436258586},

    {"count": 64, "lat": 35.4962845864725, "lng":112.858578231328},

    {"count": 26, "lat": 37.5244977495771, "lng":111.150449675291},

    {"count": 21, "lat": 38.4223833851777, "lng":112.740624160238},

    {"count": 30, "lat": 36.2012683721548, "lng":113.122558869849},

    {"count": 74, "lat": 39.3371083705417, "lng":112.439370939667},

    {"count": 15, "lat": 37.8623608478593, "lng":113.587616662875},

    {"count": 25, "lat": 36.0937418954197, "lng":111.52553022403},

    {"count": 70, "lat": 41.8414652512018, "lng":123.435597856832},

    {"count": 96, "lat": 41.6838300691906, "lng":123.471096644822},

    {"count": 75, "lat": 38.9189536667856, "lng":121.621631484592},

    {"count": 63, "lat": 41.1258752887371, "lng":122.077490090213},

    {"count": 49, "lat": 40.7173644363618, "lng":120.843398339928},

    {"count": 9, "lat": 41.100931499462, "lng":121.132596300555},

    {"count": 66, "lat": 40.0064087055936, "lng":124.36154728159},

    {"count": 23, "lat": 42.0280219013184, "lng":121.676407998658},

    {"count": 81, "lat": 41.5798208647556, "lng":120.457499497932},

    {"count": 31, "lat": 42.2299479971844, "lng":123.732365209177},

    {"count": 5, "lat": 41.4929164605529, "lng":123.692507124208},

    {"count": 69, "lat": 41.1150535969493, "lng":123.001372513994},

    {"count": 25, "lat": 41.2741612904542, "lng":123.243366406513},

    {"count": 57, "lat": 40.673136838267, "lng":122.241574664496},

    {"count": 93, "lat": 26.7028600153249, "lng":106.673075994352},

    {"count": 86, "lat": 26.6533248223097, "lng":106.636576763527},

    {"count": 47, "lat": 27.2902150834259, "lng":105.298588795011},

    {"count": 32, "lat": 27.7317008789166, "lng":106.933427748018},

    {"count": 36, "lat": 26.5988331082574, "lng":104.837554602346},

    {"count": 20, "lat": 26.2606161960738, "lng":107.528402705737},

    {"count": 63, "lat": 26.6040295449949, "lng":106.714475930885},

    {"count": 21, "lat": 26.589702969826, "lng":107.989446240778},

    {"count": 84, "lat": 26.2592523787149, "lng":105.954417123889},

    {"count": 2, "lat": 25.0939673494165, "lng":104.912492146269},

    {"count": 73, "lat": 39.0936678434039, "lng":117.20952321467},

    {"count": 9, "lat": 39.7231944829331, "lng":117.316600692476},

    {"count": 59, "lat": 39.1344873259551, "lng":117.258412953068},

    {"count": 50, "lat": 39.1534851447047, "lng":117.203592781355},

    {"count": 37, "lat": 39.1233902532797, "lng":117.2214669949},

    {"count": 26, "lat": 39.0936678434039, "lng":117.20952321467},

    {"count": 26, "lat": 39.1487266089665, "lng":117.014410179936},

    {"count": 50, "lat": 39.1157180822155, "lng":117.229416280019},

    {"count": 75, "lat": 39.3369564312272, "lng":117.832393343418},

    {"count": 6, "lat": 39.0923323428145, "lng":117.320568507914},

    {"count": 16, "lat": 39.0094157736466, "lng":117.71739882966},

    {"count": 63, "lat": 39.1441052797677, "lng":117.156515374324},

    {"count": 33, "lat": 39.1732856465641, "lng":117.157517883273},

    {"count": 85, "lat": 38.9441485681146, "lng":117.36338677903},

    {"count": 61, "lat": 39.2303439099184, "lng":117.141402731577},

    {"count": 81, "lat": 36.0601736093078, "lng":103.842102034372},

    {"count": 79, "lat": 36.0672346935455, "lng":103.840521196336},

    {"count": 29, "lat": 34.5874118816506, "lng":105.731416745669},

    {"count": 73, "lat": 35.5868329265618, "lng":104.632420083063},

    {"count": 30, "lat": 33.4066202299512, "lng":104.928574970711},

    {"count": 87, "lat": 36.5508253304145, "lng":104.144450828343},

    {"count": 14, "lat": 35.6075621835031, "lng":103.216390565297},

    {"count": 96, "lat": 34.9891399099682, "lng":102.917584688258},

    {"count": 78, "lat": 35.5492320504635, "lng":106.671442348277},

    {"count": 39, "lat": 38.9320660070049, "lng":100.456411474056},

    {"count": 18, "lat": 35.715215983562, "lng":107.649385695954},

    {"count": 14, "lat": 38.5258200920926, "lng":102.194605686698},

    {"count": 40, "lat": 36.0654648873676, "lng":103.832478128122},

    {"count": 81, "lat": 43.8435678345792, "lng":126.555634504954},

    {"count": 52, "lat": 43.8219535010431, "lng":125.330602075906},

    {"count": 73, "lat": 43.171993571561, "lng":124.356481557158},

    {"count": 88, "lat": 42.9157430337218, "lng":129.477376320227},

    {"count": 68, "lat": 43.8435678345792, "lng":126.555634504954},

    {"count": 13, "lat": 42.8940550057463, "lng":125.150425166887},

    {"count": 23, "lat": 43.510832663153, "lng":124.829448660709},

    {"count": 31, "lat": 41.7338158016134, "lng":125.94660627598},

    {"count": 37, "lat": 45.1474041934138, "lng":124.831481875692},

    {"count": 62, "lat": 40.8231562324461, "lng":111.772605830819},

    {"count": 89, "lat": 39.6144823139488, "lng":109.787443179236},

    {"count": 23, "lat": 40.6629287882613, "lng":109.846543507212},

    {"count": 58, "lat": 40.8484229971134, "lng":111.755508561709},

    {"count": 68, "lat": 49.2184464755648, "lng":119.772370499466},

    {"count": 57, "lat": 40.7493594895728, "lng":107.394398083724},

    {"count": 11, "lat": 42.2616861034116, "lng":118.895520397519},

    {"count": 51, "lat": 41.0007483276738, "lng":113.139467674463},

    {"count": 3, "lat": 44.4897594978097, "lng":116.118500540584},

    {"count": 96, "lat": 43.6579800839166, "lng":122.250521787376},

    {"count": 57, "lat": 39.6620063648907, "lng":106.800391049996},

    {"count": 0, "lat": 46.0884637132189, "lng":122.044364525825},

    {"count": 90, "lat": 38.4644533465153, "lng":106.171169452141},

    {"count": 1, "lat": 38.4924600555095, "lng":106.2384935874},

    {"count": 88, "lat": 38.0037129134533, "lng":106.205371266636},

    {"count": 26, "lat": 37.5057014187029, "lng":105.203570900887},

    {"count": 57, "lat": 36.0216172580109, "lng":106.248577426071},

    {"count": 38, "lat": 38.4768779679108, "lng":106.265604807013},

    {"count": 95, "lat": 38.989682839915, "lng":106.390600425504},

    {"count": 97, "lat": 36.6518621960967, "lng":117.005425418056},

    {"count": 81, "lat": 43.7874871155032, "lng":87.6302030143597},

    {"count": 1, "lat": 36.6518621960967, "lng":117.005425418056},

    {"count": 25, "lat": 36.6518621960967, "lng":117.005425418056},

    {"count": 41, "lat": 44.0168541599198, "lng":87.3150016244744},

    {"count": 55, "lat": 36.6518621960967, "lng":117.005425418056},

    {"count": 71, "lat": 36.6518621960967, "lng":117.005425418056},

    {"count": 83, "lat": 42.9569848487712, "lng":89.1972972460079},

    {"count": 83, "lat": 41.1750298600774, "lng":80.266943484735},

    {"count": 46, "lat": 36.6518621960967, "lng":117.005425418056},

    {"count": 67, "lat": 31.8576856026453, "lng":106.775513107711},

    {"count": 22, "lat": 36.6271585792345, "lng":101.786461835867},

    {"count": 4, "lat": 36.6233846965166, "lng":101.784450170508},

    {"count": 58, "lat": 36.9606628241298, "lng":100.907434321455},

    {"count": 40, "lat": 22.536151423658, "lng":114.068846455568},

    {"count": 69, "lat": 29.6500402747677, "lng":91.1208239154639}];

    heatmapOverlay = new BMapLib.HeatmapOverlay({"radius":20});

    map.addOverlay(heatmapOverlay);

    //调整max的值效果会不一样,但count值一定要在max值之内

    heatmapOverlay.setDataSet({data: res,max:100});

    展开全文
  • 热力图数据

    2019-02-13 18:11:00
    热力图点数据和示例,arcgis for jsapi 4.10。用于展示热力图效果。数据格式为JSON。
  • leaflet热力图

    2019-02-13 15:58:52
    基于leaflet地图实现类似百度地图里的热力图(谷歌地图里的热图)
  • 在应用echart实现热力图时 出现了一个疑问,可以使地图和热力图渲染分开进行么 实现一次地图显示 多次不同数据渲染 就不用每次在option加bmap进行地图显示 bmap: { center: [120.13066322374, 30.240018034923], ...

    在应用echart实现热力图时 出现了一个疑问,可以使地图和热力图渲染分开进行么  实现一次地图显示 多次不同数据渲染 就不用每次在option加bmap进行地图显示

    bmap: {
                center: [120.13066322374, 30.240018034923],
                zoom: 14,
                roam: true
            },

    首先在public/index.html里加上 百度地图api

    <script type="text/javascript" src="https://api.map.baidu.com/api?v=3.0&ak=你的key"></script>

    定义容器放地图 和热力图渲染

    <div ref="map" style="width: 100%;height: 100%"></div>

    然后methods里定义函数 创建地图

    methods: {
            //创建百度地图
            creatMap(){
                const myChart = echarts.init(this.$refs.map);
                const option = {
                    bmap: {
                        center: [120.13066322374, 30.240018034923],
                        zoom: 8,
                        mapStyleV2: {
                            styleId: '50aa27f5dc9a72aff522ccefb0da0e83'
                        },
                        roam: true
                    },
                }
                myChart.setOption(option)
            }
    }

    在mounted里初始化地图

    mounted() {
            this.creatMap()
        }

    效果:

     再进行热力图渲染

    直接使用echart热力图例子 https://www.echartsjs.com/examples/zh/editor.html?c=heatmap-bmap

    //渲染热力图
    drawHeat(){
                const points = [].concat.apply([], data.map(function (track) {
                    return track.map(function (seg) {
                        return seg.coord.concat([1]);
                    });
                }));
                const myChart = echarts.getInstanceByDom(this.$refs.map)
                const option = {
                    animation: false,
                    visualMap: {
                        show: false,
                        top: 'top',
                        min: 0,
                        max: 5,
                        seriesIndex: 0,
                        calculable: true,
                        inRange: {
                            color: ['blue', 'blue', 'green', 'yellow', 'red']
                        }
                    },
                    series: [{
                        type: 'heatmap',
                        coordinateSystem: 'bmap',
                        data: points,
                        pointSize: 5,
                        blurSize: 6,
                        gradientColors: [{
                            offset: 0.4,
                            color: 'green'
                        }, {
                            offset: 0.5,
                            color: 'yellow'
                        }, {
                            offset: 0.8,
                            color: 'orange'
                        }, {
                            offset: 1,
                            color: 'red'
                        }]
                    }]
                }
                myChart.setOption(option)
            }

     这里没有加bmap 因为前面creatMap函数已经渲染了地图,里面的data是官方的json数据 我下载到本地同级目录了

    json数据地址:https://www.echartsjs.com/examples/data/asset/data/hangzhou-tracks.json

    echarts.getInstanceByDom(this.$refs.map)是获取当前echart实例 在该实例上进行热力图操作

    添加了点击按钮 点击就渲染热力图 效果如图:

     这样 方便渲染其他数据下的热力图 或者刷新 

    其中如果想对地图进行其他操作  百度地图API里的操作 只需获取到该地图实例就可以了

    也可以算是echarts里调用百度地图

    //获取当前echart实例
    const myChart=echarts.getInstanceByDom(this.$refs.map)
    // 添加百度地图插件 map为当前地图实例
    const map = myChart.getModel().getComponent('bmap').getBMap();

     代码结构:

    遇到什么问题,可留言,看到会尽快回复。

    展开全文
  • A 热力图热力图以高亮形式显示数据密集程度。根据密集程度的不同,图上会呈现不同的颜色,以直观的形式展现数据密度。在设备检测领域,采用热力图可以直观地显示哪些区域的设备具有很高的报警率,为监控决策和提前...
  • 根据地理区域数据的可视化,除了在地图上添加散点之外,我们也可以制作地图类型的热力图,详细介绍:https://blog.csdn.net/qq_36437172/article/details/106121650
  • 1.需求上篇说到可以批量获得地址的经纬度,根据这些经纬度及数量,就可以画出热力图了,热力图有挺多工具可以画的,例如,BDP,Echarts等。这里就用百度地图API来画热力图。2.过程1.获取ak在百度地图开放平台上,...
  • 百度热力图和高德热力图对比

    万次阅读 2018-01-23 15:36:53
    1.百度热力图 前提:百度地图的热力图目前只支持有canvas支持的浏览器  步骤: 1.建立地图图层 var map=new BMap.map('mapconElement')  /*2.设置地图的中心点和缩放(建议设置 默认的是 lng:0,...
  • 一)热力图热力图是利用获取的手机基站定位该区域的用户数量,通过用户数量渲染地图颜色。通过坐标信息,实时展示该地区的人口密度。拿起手机——打开“百度地图”APP——点击右侧“图层”——在“地图设置”一栏,...
  • 热力图源码

    2018-10-15 16:51:54
    本代码简单介绍python热力图如何绘制的,仅供大家分享和参考。
  • 最简单的地图热力图,用的是百度的api,所以取经纬度的时候最好也用百度地图。 这里已经填好百度api的key了,但还是建议大家注册使用自己的key,因为有每日额度,超过访问次数了就不可用了。 <script type=...
  • 高德热力图动态切换

    2019-04-17 09:50:52
    高德地图,高德热力图,高德地图热力图,热力动态,热力图动态打点
  • 这一篇是leaflet动态地图的第四篇,也是最值得推荐的一篇,这一篇涉及到热力地图填充,通过该篇内容,大家可以体会大leaflet在线地图的R借口在处理热力地图上面颜色标度映射的强大优势。加载包:library(plyr)...
  • 地图热力图

    2019-03-29 16:55:07
    介绍两款R画地图热力图的包: 一、REmap包 此包的安装有点麻烦,当时一直安装不上,先推荐正常的安装方法,如果遇到问题,下面有几个链接,提供了一系列解决办法,可供参考。 REmap包安装: install.package(...
  • 热力图是数据可视化项目中,比较常用的显示方式。通过颜色变化程度,他可以直观反应出热点分布,区域聚集等数据信息。屏幕快照 2017-02-10 下午3.45.52.png项目概述我们的项目任务是统计场馆中参观者的实时区域分布...
  • 首先先看下2d热力图和3d热力图生成的效果图区别业务及技术痛点很多行业数据使用3D热力图表达更为直观目前的2D热力图表现力较差,且较为平淡技术解决方案使用Canvas绘制2D热力图方法回顾:准备包含权重值的热力点数据...
  • 百度地图 热力图及轨迹图展示

    万次阅读 热门讨论 2016-05-24 11:28:46
    此为热力图效果: 此为轨迹图效果: 下面分别详细说明: 1.热力图相对简单,只要调用百度地图的js接口即可。 <script type="text/javascript" src="http://api.map.baidu.com/api?v=2.0&ak=">...
  • 1.热力图简介热力图主要是用来可视化矩阵及矩阵中值的大小,我们只需要把关注的数据放到矩阵中,从而利用热力图可视化矩阵。热力图的应用范围很广,可以用来显示各区域的密度,也可以用来显示各变量之间的相关性。2....

空空如也

空空如也

1 2 3 4 5 ... 20
收藏数 3,977
精华内容 1,590
关键字:

热力图