title: loading a VCF file into memory, and then, reading it with pyvcf
body: <p>I am new in python and bioinformatics.</p>
  
  <p>I am trying to first load a VCF file into the memory, and then parse it with the pyvcf library, but I am getting this error:"IndexError: list index out of range* "
  I have searched in the internet, but I didn't find any answers.</p>
  
  <p>By the way, the code is: </p>
  
  <pre><code>import mmap
  import vcf
  file_chr_mt_vcf = 'ALL.chrMT.phase3_callmom-v0_4.20130502.genotypes.vcf'
  chr_mt = open(file_chr_mt_vcf, 'rb')
  m = mmap.mmap(chr_mt.fileno(), 0, access = True)
  chr_mt = vcf.Reader(m)
  for i in chr_mt:
      print i.is_snp 
  </code></pre>
  
  <p>What should I do? Is there any better way to do this?</p>
  
  <p>It should be mentioned that changing the pyvcf library and move to another one is impossible because I have written hundreds of lines of code to do some tasks. I just want to load the vcf file into memory and then do those tasks with pyvcf. </p>