5.6.2.2. statsmodels.sandbox.infotheo.condentropy¶
-
statsmodels.sandbox.infotheo.
condentropy
(px, py, pxpy=None, logbase=2)[source]¶ Return the conditional entropy of X given Y.
Parameters: px : array-like
py : array-like
pxpy : array-like, optional
If pxpy is None, the distributions are assumed to be independent and conendtropy(px,py) = shannonentropy(px)
logbase : int or np.e
Returns: sum_{kj}log(q_{j}/w_{kj}
where q_{j} = Y[j]
and w_kj = X[k,j]