convert.vcf: convert .vcf files to MatrixEQTL genotype input

Description Usage Arguments Value Author(s)

View source: R/eqtl_lib.R

Description

convenience function to convert genotypes from .vcf files to the MatrixEQTL format

Usage

1
2
convert.vcf(vcf.file, which = "GT", map = FALSE, snp.pos = FALSE,
  genotype_file_name = NULL)

Arguments

vcf.file

vcf.file containing genotypes

which

which field of the .vcf file to use: "GT" = genotype, "DS" = genotype dosage from MaCH/Thunder, "GL" = genotype likelihoods (default "GT")

map

should the map object extracted from

snp.pos

names for colums with annotations for custom build, order: chromosome (chr), length (pos) (default NULL)

genotype_file_name

Value

either a matrix nsnps x nsample containing genotypes coded as 0,1,2 or a list with slots "gt.mat", "map", "snp.pos"

Author(s)

Ines Assum (2019-03-21)


matthiasheinig/eQTLpipeline documentation built on May 21, 2019, 1:16 p.m.