Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork8.1k
Closed
Milestone
Description
The issue was discovered here
deeptools/pyGenomeTracks#37
Basically, when fill_between encounters a NaN in the y values, when interpolate=True it produces a strange output.
This is without interpolation:
importmatplotlib.pyplotaspltimportnumpyasnpx=np.arange(107).astype(float)y=np.append(np.zeros((100))+0.01, [0.5,0.75,1,np.nan,1,0.75,0.5])plt.figure(figsize=(20,5))plt.fill_between(x,y,interpolate=False)
If I turn interpolation on (which I wouldn't expect to do anything in this case, since there are not zero crossings), this is what I get:
plt.figure(figsize=(20,5))plt.fill_between(x,y,interpolate=True)
Even if I am misunderstanding something about how interpolation is supposed to work, clearly this is not what it should do...
mpl 2.1.2, python 3.5.2

