I am working on variant calling. My goal is to get the chromosome positions from vcf file and coverage on positive and negative strands. I am using pysam and pyvcf modules in python. While executing the python script it throws error
TypeError: argument of type 'int' is not iterable.
I understand what it means. How can I overcome this error?
I need suggestions to succeed in dealing with this problem?
import vcf, glob, pysam, csv from os.path import basename
Can you give a traceback of the error or at least the line number where it is occurring? It would be faster than to go through hundred-odd rows of your code manually.
P.S. you do not need semicolons at the end of the lines in python. in fact, that is considered bad style.
I still occasionally do that myself. I blame C :)
The error takes place at line 74.
Thanks for notifying me that about semicolon(;) at the end of line and I'll follow this suggestion from now on.
Can you highlight the line where the error is happening ?
The line number 74
is the line throws error.
I've put your code in a code block, which will hopefully help formatting a bit.
Thanks @Devon Ryan