snp.data-class {GenABEL} | R Documentation |
This class contains objects holding large arrays of single nucleotide polymorphism (SNP) genotypes
nbytes
:nids
:male
:idnames
:nsnps
:nsnpnames
:chromosome
:coding
:strand
:map
:gtps
:snp.mx-class
object used to store genotypessignature(x = "snp.data", i = "ANY", j = "ANY", drop = "ANY")
: subset
operations. x[i,j] will select people listed in i and SNPs listed in j.signature(from = "snp.data", to = "numeric")
:
map to codes 0, 1, 2, or NAsignature(from = "snp.data", to =
"character")
: map to actual nucleotide codes, e.g. "A/A", "A/G", "G/G", ""signature(from = "snp.data", to =
"genotype")
: map to data frame with genotype
-class
data, for later use with package genetics
signature(from = "snp.data", to =
"hsgeno")
: map to data frame with allelic data frame,
for later use with package haplo.stats
signature(object = "snp.data")
: shows the object.
Take care that the objects are usually very large!signature(object = "snp.data")
: calculate
allele frequencies, genotype frequencies, and chi-square tests for
Hardy-Weinberg equilibrium. Results are returned as a dataframeYurii Aulchenko
gwaa.data-class
,
snp.data
,
snp.mx-class
data(srdta) class(srdta) x <- srdta@gtdata class(x) x@nids x@nsnps x@idnames[1:12] x@male[1:12] x@male[c("p1","p2","p3","p4")] x@snpnames[1:4] x@chromosome[1:4] x@map[1:4] n4 <- c("rs18","rs655") n4 x@map[n4] n4 <- c("rs18","rs65") n4 x@map[n4] x@chromosome[n4] x[1:12,1:4] summary(x[,1:10]) as.numeric(x[1:12,1:4]) as.numeric(x[c("p1","p3","p4"),c("rs18","rs65")]) as.character(x[c("p1","p3","p4"),c("rs18","rs65")]) as.genotype(x[c("p1","p3","p4"),c("rs18","rs65")]) as.hsgeno(x[c("p1","p3","p4"),c("rs18","rs65")])