powered by
Mantel-Haenszel odds ratio calculation and graphing from a stratified case-control study
mhor(..., mhtable = NULL, decimal=2, graph = TRUE, design = "cohort")
Three variables viz. 'outcome', 'exposure' and 'stratification'.
a 2-by-2-by-s table, where s (strata) is more than one
number of decimal places displayed
If TRUE (default), produces an odds ratio plot
Specification for graph; can be "case control","case-control", "cohort" or "prospective"
Virasakdi Chongsuvivatwong cvirasak@gmail.com
'mhor' computes stratum-specific odds ratios and 95 percent confidence intervals and the Mantel-Haenszel odds ratio and chi-squared test is given as well as the homogeneity test. A stratified odds ratio graph is displayed.
'fisher.test', 'chisq.test'
data(Oswego) with(Oswego, cc(ill, chocolate)) with(Oswego, mhor(ill, chocolate, sex)) mht1 <- with(Oswego, table(ill, chocolate, sex)) dim(mht1) mhor(mhtable=mht1) # same results
Run the code above in your browser using DataLab