Я пытаюсь нарисовать эллипсы на проекции базовой карты. Для рисования круга, такого как многоугольник, существует функция tissot
, используемая для рисования Tissot indicatrix, как показано в следующем примере.
from mpl_toolkits.basemap import Basemap
x0, y0 = 35, -50
R = 5
m = Basemap(width=8000000,height=7000000, resolution='l',projection='aea',
lat_1=-40.,lat_2=-60,lon_0=35,lat_0=-50)
m.drawcoastlines()
m.tissot(x0, y0, R, 100, facecolor='g', alpha=0.5)
Однако меня интересует построение многоточия в форме (x-x0)**2/a**2 + (y-y0)**2/2 = 1
. С другой стороны, для рисования многоточия на обычной картезианской сетке я могу использовать следующий пример кода:
import pylab
from matplotlib.patches import Ellipse
fig = pylab.figure()
ax = pylab.subplot(1, 1, 1, aspect='equal')
x0, y0 = 35, -50
w, h = 10, 5
e = Ellipse(xy=(x0, y0), width=w, height=h, linewidth=2.0, color='g')
ax.add_artist(e)
e.set_clip_box(ax.bbox)
e.set_alpha(0.7)
pylab.xlim([20, 50])
pylab.ylim([-65, -35])
Есть ли способ построить многоточие на проекции базовой карты с эффектом, похожим на tissot
?