[R] Table of P values for Fisher's exact test

jenny tan jennytimp at hotmail.com
Tue Jul 11 11:29:15 CEST 2006


Hi,

I have a table of observed counts for various genetic markers. Instead of 
doing Fisher's exact test for each marker one at a time and recording the P 
value manually, is there a script to go through the whole list and generate 
the P value column automatically?

An example of my data:


Counts_CHB and Counts_AA are the observed counts for one allele.
2N_CHB and 2N_AA are the total number of alleles.

gene	Local_Pos	2N_CHB	2N_AA	Counts_CHB	Counts_AA     Exact_P
B2M	2475	90	46	0	5
B2M	3532	90	44	0	1
FCN2	2203	88	46	0	1
FCN2	3536	90	46	0	9
FCN2	4027	84	46	0	9
FCN2	4036	90	46	0	9
FCN2	4318	90	46	0	9
FCN2	4392	90	46	0	9
FCN2	9575	90	46	0	1



More information about the R-help mailing list