vcf2vranges: Load a VCF file

View source: R/vcf2ranges.R

vcf2vrangesR Documentation

Load a VCF file

Description

This function loads raw VCF file into a VRanges-class object.

Usage

vcf2vranges(
  vcfFile = NULL,
  genoField = NULL,
  translateBases = TRUE,
  genome = "hg38",
  phased = FALSE,
  region = NULL,
  sample = NULL
)

Arguments

vcfFile

A path to a VCF file to be loaded.

genoField

A vector of genotype IDs to be loaded from VCF [e.g. 'GT']

translateBases

Set to TRUE if REF and ALT alleles should be reported as A,C,G or T.

genome

A reference genome used by readVcfAsVRanges function. [e.g. 'hg38' - human]

phased

If set to TRUE all unphased variants are removed.

region

A GRanges object of genomic regions to be loaded from input VCF file.

sample

A user defined set of sample IDs to be loaded.

Value

A VRanges-class object.

Author(s)

David Porubsky


daewoooo/StrandPhaseR documentation built on April 7, 2024, 7:13 p.m.