Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Unable to fetch records from indexed VCF file #113

Closed
DSrcl opened this Issue · 1 comment

2 participants

@DSrcl

Here are my python lines trying to fetch some records from one of the example VCF files in you repo:

vcf_reader = vcf.Reader(filename='tb.vcf.gz')

for record in vcf_reader.fetch('20', 1110696, 1230237):
print record

It prints nothing however.

@martijnvermaat
Collaborator

Works for me:

martijn@aida:~/projects/PyVCF[:master-]$ python
Python 2.7.3rc2 (default, Apr 22 2012, 22:30:17) 
[GCC 4.6.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import vcf
>>> vcf_reader = vcf.Reader(filename='vcf/test/tb.vcf.gz')
>>> for r in vcf_reader.fetch('20', 1110696, 1230237):
...     print r
... 
Record(CHROM=20, POS=1110696, REF=A, ALT=[G, T])
Record(CHROM=20, POS=1230237, REF=T, ALT=[None])
>>> 

Closing this one, but feel free to create a new issue if the problem persists.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.