readVCF requires the argument "genome". What does it stand for?
1
0
Entering edit mode
naive • 0
@e3519b66
Last seen 3.7 years ago

In the Introduction to VariantAnnotation I find the following peace of code.

> library(VariantAnnotation)
> fl <- system.file("extdata", "chr22.vcf.gz", package="VariantAnnotation")
> vcf <- readVcf(fl, "hg19")

While most parts seem to be clear to me, I struggle to understand the meaning of "hg19", which is presumably the input for the argument >genome<. I am working with a different data set and I am wondering, what kind of information needs to be entered at this point.

Thank you for your help!

Genome readVcf VariantAnnotation • 1.6k views
ADD COMMENT
0
Entering edit mode
@james-w-macdonald-5106
Last seen 10 hours ago
United States

This is explained in ?readVcf:

  genome: A 'character' or 'Seqinfo' object.

             'character': Genome identifier as a single string or
              named character vector. Names of the character vector
              correspond to chromosome names in the file. This
              identifier replaces the genome information in the VCF
              'Seqinfo' (i.e., 'seqinfo(vcf)').  When not provided,
              'genome' is taken from the VCF file header.

             'Seqinfo': When 'genome' is provided as a 'Seqinfo' it is
              propagated to the VCF output. If seqinfo information can
              be obtained from the file, (i.e.,
              seqinfo(scanVcfHeader(fl)) is not empty), the output
              'Seqinfo' is a product of merging the two.

              If a param (i.e., ScanVcfParam) is used in the call to
              'readVcf', the seqlevels of the param ranges must be
              present in 'genome'.

So you have choices. If the VCF has a genome in the header, you can just use that. Or if you can provide a character string that identifies your genome, presuming you know what it is. Or you can provide a Seqinfo object. I leave it up to you to find out what that is. Learning to read and digest help pages is a skill you will need if you plan on doing this, so consider that some homework.

ADD COMMENT
0
Entering edit mode

Thank you! That helps!

ADD REPLY

Login before adding your answer.

Traffic: 695 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6