基于u-统计量的方差估计(evbus)
EVBUS的Python项目详细描述
这是本文的python实现:mentch,l.和hooker,g.通过置信区间和假设检验来量化随机森林中的不确定性。j.马赫。学习res。17,1–41(2016年)。
安装
pip install EVBUS
用法
from EVBUS import calculate_variance from sklearn.datasets import load_boston import sklearn.model_selection as xval boston = load_boston() Y = boston.data[:, 12] X = boston.data[:, 0:12] bos_X_train, bos_X_test, bos_y_train, bos_y_test = xval.train_test_split(X, Y, test_size=0.3) v = calculate_variance(bos_X_train, bos_y_train, bos_X_test, reg=True) print(v)