subset.haplohh {rehh} | R Documentation |
Subsets object of haplohh-class
Description
Subsets the data of an object of class haplohh-class
,
meeting certain conditions.
Usage
## S3 method for class 'haplohh'
subset(
x,
select.hap = NULL,
select.mrk = NULL,
min_perc_geno.hap = NA,
min_perc_geno.mrk = 100,
min_maf = NA,
max_alleles = NA,
verbose = TRUE,
...
)
Arguments
x |
object of class |
select.hap |
expression, indicating haplotypes to select. |
select.mrk |
expression, indicating markers to select. |
min_perc_geno.hap |
threshold on percentage of missing data for haplotypes
(haplotypes with less than |
min_perc_geno.mrk |
threshold on percentage of missing data for markers (markers genotyped on less than
|
min_maf |
threshold on the Minor Allele Frequency. Markers having a MAF lower than or equal to minmaf are discarded.
In case of multi-allelic markers the second-most frequent allele is referred to as minor allele.
Setting this value to zero eliminates monomorphic sites. Default is |
max_alleles |
threshold for the maximum number of different alleles at a site. Default is |
verbose |
logical. If |
... |
further arguments are ignored. |
See Also
Examples
#example haplohh object (280 haplotypes, 1424 SNPs)
#see ?haplohh_cgu_bta12 for details
data(haplohh_cgu_bta12)
#select subset of first 10 hyplotypes and first 5 markers
subset(haplohh_cgu_bta12, select.hap = 1:10, select.mrk = 1:5)