igvteam / igv-reports

Python application to generate self-contained pages embedding IGV visualizations, with no dependency on original input files.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

INFO field parsing

georgiesamaha opened this issue · comments

Hi,

Thank you for igv-reports, its a great tool. I am currently using it to visualise structural variants and wanted to include some additional INFO fields in the variants table. Using the IGVreports biocontainer v1.6.1 and Singularity, I ran the following:

vcf=/data/Results/sample_recessive.vcf.gz 
bam=/data/Bams/sample_sorted.bam

singularity run -B /data igv-reports_1.6.1--pyh7cba7a3_0.sif \
create_report \
	${vcf} \
	--genome hg38 \
	--info-columns SVTYPE SVLEN CHR2 END \
	--flanking 1000 \
	--tracks ${vcf} ${bam} \
	--output /data/Results/sample_igvreport.html

However, in the .html report only only the CHROM, POSITION, REF, ALT, ID, SVTYPE, SVLEN, CHR2 columns are filled in for each variant site. I have confirmed the END INFO field is contained within my VCF header and I am correctly naming it:

##INFO=<ID=END,Number=1,Type=Integer,Description="End position of the structural variant">

Are only some INFO fields currently supported? Would appreciate any help on understanding/resolving this :)

I think you've hit a special problem with the END property in pysam, it is a bug but doesn't look like its going to be fixed there anytime soon, see pysam-developers/pysam#973. As igv-reports uses pysam to parse VCF the "END" info-column is not visible (to IGV).

Also, btw, the suggestion to use "record.stop" for "END" at pysam-developers/pysam#973 does not work reliablity for inter-chromosomal rerrangements, I suspect there is some condition that doesn't allow records.stop to be < record.pos, although there is no such restriction for the "END" info field.

Ah thank you @jrobinso!