<< nan_fss Classification nan_mahal >>

NaN Toolbox >> NaN Toolbox > Classification > nan_kappa

nan_kappa

estimates Cohen's kappa coefficient

Calling Sequence

[...] = nan_kappa(d1,d2);
NaN's are handled as missing values and are ignored
[...] = nan_kappa(d1,d2,'notIgnoreNAN');
NaN's are handled as just another Label.
[kap,sd,H,z,ACC,sACC,MI] = kappa(...);
X = nan_kappa(...);

Parameters

d1 :

data of scorer 1

d2 :

data of scorer 2

kap:

Cohen's kappa coefficient point

se:

standard error of the kappa estimate

H:

Confusion matrix

z:

z-score

ACC:

overall agreement (accuracy)

sACC:

specific accuracy

MI :

Mutual information or transfer information (in [bits])

X :

is a struct containing all the fields above

X.TP:

number of true positive instances

X.FN:

false negative instances

X.FP:

false positive instances

X.TN:

true negative instances

X.RPP :

Rate of positive predictions. RPP=(TP+FP)/(TP+FN+FP+TN)

X.RNP :

Rate of negative predictions. RNP=(TN+FN)/(TP+FN+FP+TN)

X.TPR :

True positive rate . TPR = TP/(TP+FN)

X.FNR :

False negative rate. FNR=FN/(TP+FN)

X.FPR :

False positive rate. FPR=FP/(TN+FP)

X.TNR :

True negative rate. TNR=TN/(TN+FP)

X.PPV :

Positive predictive value. PPV=TP/(TP+FP)

X.NPV :

Negative predictive value. NPV=TN/(TN+FN)

Description

For two classes, a number of additional summary statistics including TPR, FNR, FPR, TNR, PPV, NPV,RPP, F1, dprime, Matthews Correlation coefficient (MCC), Specificity and Sensitivity are provided. Note, the positive category must the larger label (in d and c), otherwise the confusion matrix becomes transposed and the summary statistics are messed up.

Examples

ratings1=[0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]
ratings2=[0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0]
X = nan_kappa(ratings1,ratings2)

Bibliography

[1] Cohen, J. (1960). A coefficient of agreement for nominal scales. Educational and Psychological Measurement, 20, 37-46.

[2] J Bortz, GA Lienert (1998) Kurzgefasste Statistik f|r die klassische Forschung, Springer Berlin - Heidelberg.

Kapitel 6: Uebereinstimmungsmasze fuer subjektive Merkmalsurteile. p. 265-270.

[3] http://www.cmis.csiro.au/Fiona.Evans/personal/msc/html/chapter3.html

[4] Kraemer, H. C. (1982). Kappa coefficient. In S. Kotz and N. L. Johnson (Eds.),

Encyclopedia of Statistical Sciences. New York: John Wiley & Sons.

[5] http://ourworld.compuserve.com/homepages/jsuebersax/kappa.htm

[6] http://en.wikipedia.org/wiki/Receiver_operating_characteristic

Authors

<< nan_fss Classification nan_mahal >>