【问题标题】:Is there an error in the R package, bartMachine, when looking at the confusion matrix following classification?在查看分类后的混淆矩阵时,R 包 bartMachine 是否有错误?
【发布时间】:2026-02-04 23:35:02
【问题描述】:

我正在浏览 R 的 bartMachine 小插图,最后,它有一个使用 bartMachine 解决分类问题的示例。这是使用 MASS 包中的 Pima.te 数据集。当尝试使用 bartMachine 预测“类型”时(仅遵循小插图),通过将我的结果与小插图的结果进行比较,看起来我的混淆矩阵被错误地标记了。我的错误率非常高 - 非对角线中的数字看起来非常像小插图的真正数和真负数。其他人可以证实这一点吗?

    options(java.parameters = "-Xmx5g")
    library(bartMachine)
    set_bart_machine_num_cores(4)
    data("Pima.te",package = "MASS")
    X <- data.frame(Pima.te[,-8])
    y <- Pima.te[,8]

    bart_machine_cv <- bartMachineCV(X,y)
    bart_machine_cv

【问题讨论】:

标签: r error-handling modeling


【解决方案1】:

【讨论】: