Skip to content

Commit

Permalink
DEP: Deprecate PiecewisePolynomial
Browse files Browse the repository at this point in the history
  • Loading branch information
ev-br committed Feb 12, 2014
1 parent 8e7939e commit 08112a4
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
6 changes: 6 additions & 0 deletions doc/release/0.14.0-notes.rst
Expand Up @@ -124,6 +124,12 @@ Probability calculation aliases ``zprob``, ``fprob`` and ``ksprob`` are
deprecated. Use instead the ``sf`` methods of the corresponding distributions
or the ``special`` functions directly.

``scipy.interpolate``
---------------------

``PiecewisePolynomial`` class is deprecated.


Backwards incompatible changes
==============================

Expand Down
6 changes: 6 additions & 0 deletions scipy/interpolate/polyint.py
@@ -1,5 +1,7 @@
from __future__ import division, print_function, absolute_import

import warnings

import numpy as np
from scipy.misc import factorial

Expand Down Expand Up @@ -704,6 +706,10 @@ class PiecewisePolynomial(_Interpolator1DWithDerivatives):
def __init__(self, xi, yi, orders=None, direction=None, axis=0):
_Interpolator1DWithDerivatives.__init__(self, axis=axis)

warnings.warn('PiecewisePolynomial is deprecated in scipy 0.14. '
'Use BPoly.from_derivatives instead.',
category=DeprecationWarning)

if axis != 0:
try:
yi = np.asarray(yi)
Expand Down

0 comments on commit 08112a4

Please sign in to comment.