Participer au site avec un Tip
Rechercher
 

Améliorations / Corrections

Vous avez des améliorations (ou des corrections) à proposer pour ce document : je vous remerçie par avance de m'en faire part, cela m'aide à améliorer le site.

Emplacement :

Description des améliorations :

Vous êtes un professionnel et vous avez besoin d'une formation ? Machine Learning
avec Scikit-Learn
Voir le programme détaillé
Module « scipy.special »

Fonction boxcox - module scipy.special

Signature de la fonction boxcox

def boxcox(*args, **kwargs) 

Description

help(scipy.special.boxcox)

boxcox(x1, x2, /, out=None, *, where=True, casting='same_kind', order='K', dtype=None, subok=True[, signature])

boxcox(x, lmbda, out=None)

Compute the Box-Cox transformation.

The Box-Cox transformation is::

    y = (x**lmbda - 1) / lmbda  if lmbda != 0
        log(x)                  if lmbda == 0

Returns `nan` if ``x < 0``.
Returns `-inf` if ``x == 0`` and ``lmbda < 0``.

Parameters
----------
x : array_like
    Data to be transformed.
lmbda : array_like
    Power parameter of the Box-Cox transform.
out : ndarray, optional
    Optional output array for the function values

Returns
-------
y : scalar or ndarray
    Transformed data.

Notes
-----

.. versionadded:: 0.14.0

Examples
--------
>>> from scipy.special import boxcox
>>> boxcox([1, 4, 10], 2.5)
array([   0.        ,   12.4       ,  126.09110641])
>>> boxcox(2, [0, 1, 2])
array([ 0.69314718,  1.        ,  1.5       ])


Vous êtes un professionnel et vous avez besoin d'une formation ? Machine Learning
avec Scikit-Learn
Voir le programme détaillé