if yp is None:
        yp = slopes(x, y)
    else:
        yp = np.asarray(yp, np.float_)