read_region_vcf.Rd
given region coordinates (locus), the function extracts genotypes for all loci in that region, constructs genotypes matrix G (applies imputation and fixes allele encoding) and computes maf per marker.
read_region_vcf(locus, vcf_file, force_silent = F, GP_map = c(0, 1, 2))
locus | region to extract, e.g. 22:17638600-17641201 |
---|---|
vcf_file | path to vcf file containing genotypes |
force_silent | silence seqminer verbosity (may cause some issues on non-*nix machines) |
GP_map | a genotype-phenotype map, by default AA-0, Aa-1 and aa-2 |
a list with genotypes matrix and maf vector or NULL if region cannot be extracted
Marcin Kierczak <marcin.kierczak@scilifelab.se>