subset.cross {qtl} | R Documentation |
Pull out a specified set of chromosomes and/or individuals from a
cross
object.
subset.cross(x, chr, ind, ...)
x |
An object of class cross . See
read.cross for details. |
chr |
A vector specifying which chromosomes to keep or discard. This may be a logical vector, a numeric vector, or a vector of character strings. |
ind |
A vector specifying which individuals to keep or discard. This may be a logical or numeric vector. |
... |
Ignored at this point. |
The input cross
object, but with only the specified subset
of the data.
Karl W Broman, kbroman@jhsph.edu
data(fake.f2) fake.f2.A <- subset(fake.f2, chr=c("5","13")) fake.f2.B <- subset(fake.f2, ind = -c(1,5,10)) fake.f2.C <- subset(fake.f2, chr=1:5, ind=1:50) data(listeria) y <- listeria$pheno[,1] listeriaB <- subset(listeria, ind = (!is.na(y) & y < 264))