Description Usage Arguments Value Examples
Get model evaluation statistics from a confusion matrix.
1 | evaluate(cmat, stat)
|
cmat |
confusion matrix. Normally created with table (see examples) |
stat |
character. Either "overall" (overall accuracy), "kappa", "class" for user and producer accuracy |
numeric
1 2 3 4 5 6 7 8 9 10 11 12 |
classes <- c("forest", "water", "urban", "agriculture")
set.seed(1)
observed <- sample(classes, 100, replace=TRUE)
predicted <- observed
i <- seq(1,100,2)
predicted[i] <- sample(classes, length(i), replace=TRUE)
conmat <- table(observed, predicted)
conmat
evaluate(conmat, "kappa")
evaluate(conmat, "producer")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.