Skip to contents

Error rate of a binary classifier

Usage

error_rate(y, y_hat)

Arguments

y

A numeric vector with binary entries, the true outcomes.

y_hat

A numeric vector with binary entries, the predicted outcomes.

Value

Numeric scalar, the error rate.