我正在使用 AdaBoost 分类器来预测我拥有的值。如何评估预测模型的准确性(我想看看预测值的准确性如何)。
您可以在此处查看示例:http: //scikit-learn.org/stable/modules/ensemble.html#usage
我发现了两个选项:使用混淆矩阵
from sklearn.metrics import confusion_matrix
cm = confusion_matrix(expected, y_1)
或使用交叉验证分数
scores = cross_val_score(clf_1, X_train, y_train)
print scores.mean()
还有:AdaBoostClassifier.staged_score(X, y) AdaBoostClassifier.score(X, y)
所以,我有点困惑。
最后一个问题:我应该使用 predict() 还是 predict_proba()。