[R] Mantel-Haenszel for 2x2
Dr. Jeff Miller
jeffmiller at alphapoint05.net
Sun Apr 20 01:22:40 CEST 2008
Rob,
I had tried that but mhor requires 3 variables (i.e., a conditional test). I
didn't think to just create a third variable...vector of 1's. Now it works
fine.
Thanks!
Jeff
-----Original Message-----
From: Robert Baer [mailto:rbaer at atsu.edu]
Sent: Saturday, April 19, 2008 6:48 PM
To: Dr. Jeff Miller; r-help at stat.math.ethz.ch
Subject: Re: [R] Mantel-Haenszel for 2x2
See if this is what you are looking for:
library(epicalc)
data(Oswego)
use(Oswego)
cc(ill, chocolate)
mhor(ill, chocolate, sex)
You might also wish to read the details of:
mantelhaen.test
HTH],
Rob Baer
----- Original Message -----
From: "Dr. Jeff Miller" <jeffmiller at alphapoint05.net>
To: <r-help at stat.math.ethz.ch>
Sent: Saturday, April 19, 2008 1:30 AM
Subject: [R] Mantel-Haenszel for 2x2
Hi all,
Does anyone know if an R function for the Mantel-Haenszel chi-square for a
2x2 table exists? I've also seen it called the randomization Q statistic.
Note that I'm not looking for the Cochran-Mantel-Haenszel.I did see that out
there as cmh.test.
Thanks in advance,
Jeff
Internal Virus Database is out-of-date.
Checked by AVG Free Edition.
11:27 AM
[[alternative HTML version deleted]]
----------------------------------------------------------------------------
----
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>
Internal Virus Database is out-of-date.
Checked by AVG Free Edition.
11:27 AM
Internal Virus Database is out-of-date.
Checked by AVG Free Edition.
11:27 AM
More information about the R-help
mailing list