Feed on
Posts
Comments

nan’s cause problems with the fill_between plots in matplotlib.

to fix, use the “where” input argument:

fig, ax = pl.subplots(1)

ax.fill_between(x_v,0,y_v,where=np.isfinite(y_v))


Bookmark and Share

if that was helpful ...

check out the other tips and tricks i've compiled on these pages. you might learn something else interesting!

Did I get this wrong? Let me know!

Trackback URI | Comments RSS