| Title: | The Matthews Correlation Coefficient |
|---|---|
| Description: | The Matthews correlation coefficient (MCC) score is calculated (Matthews BW (1975) <DOI:10.1016/0005-2795(75)90109-9>). |
| Authors: | Hitoshi Iuchi |
| Maintainer: | Hitoshi Iuchi <[email protected]> |
| License: | MIT + file LICENSE |
| Version: | 0.4.4 |
| Built: | 2026-05-17 05:25:16 UTC |
| Source: | https://github.com/cran/mccr |
Calculate the Matthews correlation coefficient (MCC) score
mccr(act, pred)mccr(act, pred)
act |
actual values (vector), 1 (positive), or 0 (negative) |
pred |
predict values (vector), 1 (positive), or 0 (negative) |
MCC score
set.seed(18) act <- abs(round(rnorm(100))) %% 2 pred <- abs(round(rnorm(100))) %% 2 mccr(act, pred)set.seed(18) act <- abs(round(rnorm(100))) %% 2 pred <- abs(round(rnorm(100))) %% 2 mccr(act, pred)