如何使用python中的Basemap减少我在地图上绘制的地点的点大小?
绘图的代码是:
m = Basemap(width=4000000,height=4000000,projection='lcc',
resolution='c',lat_1=45.,lat_2=55,lat_0=20,lon_0=80.)
m.drawmapboundary(fill_color='aqua')
m.drawcountries()
m.drawcoastlines(linewidth=0.50)
m.fillcontinents(color='green', alpha = 0.6, lake_color='aqua')
for i in range(len(lngtd)):
lon = lngtd[i]
lat = lattd[i]
xpt,ypt = m(lon,lat)
lonpt, latpt = m(xpt,ypt,inverse=True)
m.plot(xpt,ypt,'ro')
plt.show()
答案 0 :(得分:1)
为将来的访问者添加完整答案。将markersize关键字添加到该行:
m.plot(xpt,ypt,'ro')
制作:
m.plot(xpt,ypt,'ro', ms="2.0")
文档:https://matplotlib.org/api/_as_gen/matplotlib.pyplot.plot.html