accuracy: Compute predictive accuracy.

View source: R/basic-misc.R

accuracyR Documentation

Compute predictive accuracy.

Description

Compute predictive accuracy.

Usage

accuracy(x, y)

Arguments

x

A vector of predicted labels.

y

A vector of true labels.

Examples

 
data(car)
nb <- bnc('nb', 'class', car, smooth = 1)
p <- predict(nb, car)
accuracy(p, car$class)

bmihaljevic/bnclassify documentation built on March 18, 2024, 8:34 a.m.