Description Usage Arguments Details Value Note Author(s) See Also Examples
For quality control purposes, it is sometimes necessary to compare genotype data derived from different sources. This function facilitates this.
1 | sm.compare(obj1, obj2, row.wise = TRUE, col.wise = TRUE)
|
obj1 |
The first of the two |
obj2 |
The second |
row.wise |
Calculate comparison statistics aggregated in a row-wise manner |
col.wise |
Calculate column-wise comparison statistics |
Initially row and column names of the two objects are compared to identify subsets of subjects and SNPs which they have in common. Then, every instance of a SNP genotype in the two objects are compared and agreements and disagreements counted by row and/or by column.
If only one of the row-wise and column-wise summaries are to be calculated, the return value is a matrix with rows defined by subjects or SNPs and columns giving counts of:
Agree |
Agreements (all) |
Disagree |
Disgreements (all) |
NA.agree |
Genotype coded |
NA.disagree |
Genotype coded |
Hom.agree |
Objects agree and genotype is homozygous |
Hom.switch |
Genotype coded as homozygous in both objects, but alleles switched |
Het.agree |
Genotype coded as heterozygous in both objects |
Het.Hom |
Genotype coded as heterozygous in one object and homozygous in the other |
If both row-wise and column-wise summaries are computed (the default
behaviour) , the function
returns a list containing two matrices of the form described
above. These are named row.wise
and col.wise
No special provision is yet made for objects of class
XSnpMatrix
, in which haploid calls are coded as homozygous.
David Clayton dc208@cam.ac.uk
SnpMatrix-class
, XSnpMatrix-class
1 2 3 | ##
## No example yet available
##
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.