You could mask part of the array, then matplotlib doesn't plot it:
import numpy as np
import matplotlib.pylab as pl
x = np.arange(100)
y = np.cos(x/10.)
pl.figure()
pl.subplot(121)
pl.plot(x, y)
# Mask part of array
y2 = np.ma.masked_where(((x>20)&(x<30)), y)
pl.subplot(122)
pl.plot(x, y2)
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…