Amy Mikhail wrote:
Dear Peter,

Many thanks for your reply. Unfortunately I don't have access to the reference book.

However it looks to me like the gold standard should be in the rows and the comparison method should be in the columns for the test to give the right answer (since the location of the gold standard determines which are true and false positives, etc, which determines what the denominators of the formulae are).

I tried swapping around the negatives and positives, but that doesn't make much difference to the result (it is still the wrong way around):

 > t1
         positive negative
positive      201        1
negative        0       18

 > sensSpec(t1)

 Simple Sensitivity and Specitivity Output
Input Matrix:
         positive negative
positive      201        1
negative        0       18

The sample of sensitivity is: 100%

The sample of specificity is: 94.7%

Umm, maybe I'm not quite awake yet, but if you're switching positive and negatives, the 1 should end up in the other corner so that the gold standard has 202 positives and 18 negatives, with 1 false positive and no false negatives. I.e., the sensitivity ia 201/202 and specificity is 18/18. Transposing the tables would give you predictive probabilities, which are different beasts entirely.

....

         sensSpec(t1)

         Simple Sensitivity and Specitivity Output

        Input Matrix:
                 ref
        r1a        negative positive
         negative       18        1
         positive        0      201

        The sample of sensitivity is: 100%

        The sample of specificity is: 99.5%


--
   O__  ---- Peter Dalgaard             Ă˜ster Farimagsgade 5, Entr.B
  c/ /'_ --- Dept. of Biostatistics     PO Box 2099, 1014 Cph. K
 (*) \(*) -- University of Copenhagen   Denmark      Ph:  (+45) 35327918
~~~~~~~~~~ - (p.dalga...@biostat.ku.dk)              FAX: (+45) 35327907

_______________________________________________
R-sig-Epi@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-sig-epi

Reply via email to