Learn R Programming

FisherEM (version 1.3.2)

evalEM: The evalEM function

Description

evalEM provides a contingency table and a correct classification rate from the clustering results of the Fisher-EM algorithm and another partition of data. The number of clusters has to be the same between both partitions

Usage

evalEM(cls, obj, disp = 1)

Arguments

cls
is a numerical vector containing reference labels.
obj
the object obtained by the fem() function
disp
if disp=1 then the contingency table is displayed.

Value

  • lblthe permuted groups
  • txthe correct classification rate

See Also

fem, plot.fem

Examples

Run this code
## The function is currently defined as

data(iris)
cls = as.numeric(iris[,5]); # the true numerical labels
res = fem(iris[,-5],3,model='AkB');
evalEM(cls,res)

Run the code above in your browser using DataLab