Description Usage Arguments Author(s) Examples
Presents MLE of haplotype frequencies based on Hardy-Weinberg equilibrium.
1 2 |
object |
an haplo.freq object. |
... |
unused arguments - for S3 compatibility |
Jeremy Silver
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | ### Simulating data
n<-200;
haplo.types<-rbind(c(0,0),c(1,0),c(0,1),c(1,1))
pairs<-matrix(sample(1:4,n*2,replace=TRUE),n,2) ### randomly selects haplotypes
g<-matrix(haplo.types[pairs,],n,4) ### observed genotype, haplotype-pair 1 = g[c(1,3),]
gs<-geno.setup(g);
hapfit<-haplo.freqs(g,geno.setup=gs)
summary(hapfit);
X<-matrix(1,3,1);
hapfit<-haplo.freqs(g,geno.setup=gs,haplo.design=X)
summary(hapfit);
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.