scipy.special.polygamma¶
-
scipy.special.
polygamma
(n, x)[source]¶ Polygamma function n.
This is the nth derivative of the digamma (psi) function.
- Parameters
- narray_like of int
The order of the derivative of
psi
.- xarray_like
Where to evaluate the polygamma function.
- Returns
- polygammandarray
The result.
Examples
>>> from scipy import special >>> x = [2, 3, 25.5] >>> special.polygamma(1, x) array([ 0.64493407, 0.39493407, 0.03999467]) >>> special.polygamma(0, x) == special.psi(x) array([ True, True, True], dtype=bool)