Closed asreimer closed 8 years ago
Confirmed now that this bug actually breaks overlayFov. Try running this code in the current master or develop branch and you'll see what I mean:
import matplotlib.pyplot as plt
import datetime
import davitpy.utils
from davitpy.pydarn.plotting import *
fig=plt.figure()
SDate=datetime.datetime(2014,7,8,1,15,9)
#the map Object
mObj=utils.plotUtils.mapObj(datetime=SDate,lon_0=-80,lat_0=70,showCoords='True',gridLabels='True',grid='True',height=111E3*40,width =111E3*40)
mObj.nightshade(SDate,alpha=0.2)
overlayRadar(mObj,codes='sas',fontSize=12)
overlayFov(mObj,maxGate=75,beams=[1,2,3,4,5,6,7,8,9,10,11,12,13],codes='sas',lineWidth=2,beamsColors=['green','green','green','green','green','green','green','green','green','green','green','green','green'])
Fixed by #239
As I've noted here, I think there is a bug in the mapObj
__init__
method.Running this code, we expect
myMap.ax
to be None:But running this code, we expect myMap.ax to be a
matplotlib.axes
object:You'll see that we do not get the result we expect.
The solution is to fix the offending line of code as I noted in the comment I linked to above.