Skip to content

Fixed #103 (KeyError: 'CIPOS') #111

Open
mchowdh200 wants to merge 3 commits into
hall-lab:masterfrom
mchowdh200:master
Open

Fixed #103 (KeyError: 'CIPOS') #111
mchowdh200 wants to merge 3 commits into
hall-lab:masterfrom
mchowdh200:master

Conversation

@mchowdh200
Copy link
Copy Markdown

  • This pull requests fixes issue KeyError: 'CIPOS' #103 where svtyper fails with a KeyError due to the input VCF missing "CIPOS" information.

  • Fix consists of adding a try block around the offending code and setting ci = [0, 0]

This was referenced Feb 4, 2021
@srbehera
Copy link
Copy Markdown

I am still getting CIPOS error. Could you please check the following error?

File ".../miniconda3/envs/py2/bin/svtyper", line 11, in <module>
    load_entry_point('svtyper==0.7.1', 'console_scripts', 'svtyper')()
  File ".../miniconda3/envs/py2/lib/python2.7/site-packages/svtyper/classic.py", line 575, in cli
    sys.exit(main())
  File ".../miniconda3/envs/py2/lib/python2.7/site-packages/svtyper/classic.py", line 568, in main
    args.max_ci_dist)
  File ".../miniconda3/envs/py2/lib/python2.7/site-packages/svtyper/classic.py", line 265, in sv_genotype
    ciA = confidence_interval(var, 'CIPOS', 'CIPOS95', max_ci_dist)
  File ".../miniconda3/envs/py2/lib/python2.7/site-packages/svtyper/parsers.py", line 12, in confidence_interval
    ci = map(int, var.info[tag].split(','))
KeyError: 'CIPOS'

@mchowdh200
Copy link
Copy Markdown
Author

Hi can you provide an example vcf for me to test with? I'll try to see what I can do.

@srbehera
Copy link
Copy Markdown

Sure. Here is the VCF file I am using https://bcm.box.com/s/otlv5zqdc0nbkgg1l4phskeelbfgrry9

Please let me know if you cannot download that file.

@srbehera
Copy link
Copy Markdown

It works good by adding "CIPOS=-100,100;CIEND=-100,100" to each SV entry in vcf file.

@dr-ashu-geno
Copy link
Copy Markdown

Dear @srbehera

Thank you for commenting on this post; I added "CIPOS=-100,100;CIEND=-100,100" to all my records and it worked; however, I'm worried about the genotyping results. I mean, doesn't adding "CIPOS=-100,100;CIEND=-100,100" to the variants affect the genotyping accuracy in samples?

Thank you in advance for your time,
Best regards,

@srbehera
Copy link
Copy Markdown

srbehera commented Jul 8, 2022

Hello @dr-ashu-geno
Sorry for my late response. I am not sure if it affected the accuracy of our analysis. I will take a look at the outputs and let you know if I find anything.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants