Hi there
I want to carry out a very large number (>50,000) of chi-sq tests, based on 2x2 tables, to compare cases and controls for >50,000 binary (yes/no) exposures. This is for the purpose of creating a manhattan plot of p-values.
Ordinarily I would just create lots of binary variables for the exposures and repeat the following command:
But clearly this is inefficient for so many exposures! Also, my number of exposures exceeds maxvar for Stata 13/IC, so this approach would not be possible anyway.
Any alternative suggestions would be greatly appreciated!
I want to carry out a very large number (>50,000) of chi-sq tests, based on 2x2 tables, to compare cases and controls for >50,000 binary (yes/no) exposures. This is for the purpose of creating a manhattan plot of p-values.
Ordinarily I would just create lots of binary variables for the exposures and repeat the following command:
Code:
tab casestatus exposure1, chi tab casestatus exposure2, chi tab casestatus exposure3, chi [etc...]
Any alternative suggestions would be greatly appreciated!
Comment