sesp.mcnemar: McNemar Test for Comparison of Sensitivities and...

View source: R/DTComPair.R

sesp.mcnemarR Documentation

McNemar Test for Comparison of Sensitivities and Specificities

Description

Performs a McNemar Test for comparison of sensitivities and specificities of two binary diagnostic tests in a paired study design.

Usage

sesp.mcnemar(tab)

Arguments

tab

An object of class tab.paired.

Details

The test is performed as described by McNemar (1947).

Value

A list containing:

sensitivity

A list containing test1 (sensitivity of test 1), test2 (specificity of test 2), diff (the difference in sensitivity, computed as test2 - test1), the test.statistic and the corresponding p.value.

specificity

A list containing test1 (specificity of test 1), test2 (specificity of test 2), diff (the difference in specificity, computed as test2 - test1), the test.statistic and the corresponding p.value.

method

The name of the method used to compare sensitivity and specificity, here “mcnemar”.

References

McNemar, Q. (1947). Note on the sampling error of the difference between correlated proportions or percentages. Psychometrika, 12(2):153-7.

See Also

sesp.exactbinom and tab.paired.

Examples

data(Paired1) # Hypothetical study data
ftable(Paired1)
paired.layout <- tab.paired(d=d, y1=y1, y2=y2, data=Paired1)
paired.layout 
mcnem.results <- sesp.mcnemar(paired.layout)
str(mcnem.results)
mcnem.results
mcnem.results$sensitivity["p.value"]

DTComPair documentation built on Aug. 20, 2023, 5:06 p.m.