statsmodels.nonparametric.kernel_density.KDEMultivariate.loo_likelihood¶
- KDEMultivariate.loo_likelihood(bw, func=<function KDEMultivariate.<lambda>>)[source]¶
Returns the leave-one-out likelihood function.
The leave-one-out likelihood function for the unconditional KDE.
- Parameters:¶
- bwarray_like
The value for the bandwidth parameter(s).
- func
callable
,optional
Function to transform the likelihood values (before summing); for the log likelihood, use
func=np.log
. Default isf(x) = x
.
Notes
The leave-one-out kernel estimator of \(f_{-i}\) is:
\[f_{-i}(X_{i})=\frac{1}{(n-1)h} \sum_{j=1,j\neq i}K_{h}(X_{i},X_{j})\]where \(K_{h}\) represents the generalized product kernel estimator:
\[K_{h}(X_{i},X_{j}) = \prod_{s=1}^{q}h_{s}^{-1}k\left(\frac{X_{is}-X_{js}}{h_{s}}\right)\]
Last update:
Dec 23, 2024