Learn R Programming

TrialSize (version 1.4)

McNemar.Test: McNemar Test in 2 by 2 table

Description

2 by 2 table. Test either a shift from 0 to 1 or a shift from 1 to 0 before treatment and after treatment.

\(p_{1+}=P_{10}+P_{11}, p_{+1}=P_{01}+P_{11}\)

Ho: \(p_{1+} = p_{+1}\)

Ha: not equal

The test is finding whether there is a categorical shift after treatment.

Usage

McNemar.Test(alpha, beta, psai, paid)

Arguments

alpha

significance level

beta

power = 1-beta

psai

the ratio of p01/p10

paid

the sum p10+p01

References

Chow SC, Shao J, Wang H. Sample Size Calculation in Clinical Research. New York: Marcel Dekker, 2003

Examples

Run this code
# NOT RUN {
Example.6.4.3<-McNemar.Test(0.05,0.2,0.2/0.5,.7)
Example.6.4.3
# 59

# }

Run the code above in your browser using DataLab