fritzsedlazeck / SURVIVOR

Toolset for SV simulation, comparison and filtering
MIT License
347 stars 46 forks source link

merge not working as expected #149

Closed kmurphy902 closed 3 years ago

kmurphy902 commented 3 years ago

Hi Fritz,

I am trying to merge a single CNV vcf output generated from DRAGEN for the GIAB AJ son (HG002). Here is an example input of 2 DUPs that I would expect to be merged:

chr1    142535870       DRAGEN:GAIN:chr1:142535871-142539206    N       <DUP>   138     PASS    SVTYPE=CNV;END=142539206;REFLEN=3336    GT:SM:CN:BC:PE  ./1:18.6893:37:3:208,697

chr1    142539206       DRAGEN:GAIN:chr1:142539207-144531367    N       <DUP>   150     cnvBinSupportRatio      SVTYPE=CNV;END=144531367;REFLEN=1992161 GT:SM:CN:BC:PE  ./1:3.10494:6:20:697,13

and here is what I get when I run SURVIVOR merge:

chr1    142535870       NA0020SUR       N       <DUP>   138     PASS    SUPP=1;SUPP_VEC=1;SVLEN=3336;SVTYPE=NA;SVMETHOD=SURVIVOR1.0.7;CHR2=chr1;END=142539206;CIPOS=0,0;CIEND=0,0;STRANDS=++    GT:PSV:LN:DR:ST:QV:TY:ID:RAL:AAL:CO     ./1:NA:3336:0,0:++:138:NA:DRAGEN_GAIN_chr1_142535871-142539206:NA:NA:chr1_142535870-chr1_142539206

chr1    142539206       NA0021SUR       N       <DUP>   150     PASS    SUPP=1;SUPP_VEC=1;SVLEN=1992161;SVTYPE=NA;SVMETHOD=SURVIVOR1.0.7;CHR2=chr1;END=144531367;CIPOS=0,0;CIEND=0,0;STRANDS=++ GT:PSV:LN:DR:ST:QV:TY:ID:RAL:AAL:CO     ./1:NA:1992161:0,0:++:150:NA:DRAGEN_GAIN_chr1_142539207-144531367:NA:NA:chr1_142539206-chr1_144531367 

My command is

./SURVIVOR/Debug/SURVIVOR merge sample_file.txt 5000 1 1 0 0 1000 HG002_merged.vcf

where sample_file.txt is just the input CNV vcf file name on one line:

HG002_input.vcf

Any ideas? Thanks in advance!

fritzsedlazeck commented 3 years ago

Hey @kmsteinberg I assume you ask why they are not merged right ?

I dont know if I oversee something but the SV length and thus the end points of your 2 CNV are hugely different.

CNV1: END=142539206 CNV2: END=144531367

Cheers Fritz

kmurphy902 commented 3 years ago

Yeah I was hoping I could make it work on this type of bookended event that is fragmented by DRAGEN. Le sigh. Thanks for your response!

kmurphy902 commented 2 years ago

Are you trying to merge bookended events? If so, as @fritzsedlazeck commented above, merge will not work unless the end points are within your given distance threshold.