{"body": "<h1>Source code for iCallSV.mergeFinalFiles</h1><div class=\"highlight\"><pre>\n<span></span><span class=\"sd\">&quot;&quot;&quot;</span>\n<span class=\"sd\">mergeFinalFiles</span>\n<span class=\"sd\">~~~~~~~~~~~~~~~</span>\n\n<span class=\"sd\">:Description: Merge VCF, iAnnotateSV tab and targetSeqView tab file into a single tab-delimited file</span>\n<span class=\"sd\">&quot;&quot;&quot;</span>\n<span class=\"sd\">&#39;&#39;&#39;</span>\n<span class=\"sd\">Created on May 17, 2015</span>\n<span class=\"sd\">Description: Merge VCF, iAnnotateSV tab and targetSeqView tab file into a single tab-delimited file</span>\n<span class=\"sd\">@author: Ronak H Shah</span>\n<span class=\"sd\">::Input::</span>\n<span class=\"sd\">aId: Sample ID for case that has the structural abberations</span>\n<span class=\"sd\">bId: Sample ID for control</span>\n<span class=\"sd\">vcfFile: Delly filtered and merged VCF file</span>\n<span class=\"sd\">annoTab: iAnnotateSV tab-delimited file with annotations</span>\n<span class=\"sd\">confTab: targetSeqView tab-delimited file with probability score</span>\n<span class=\"sd\">outputDir: Directory to write the output file</span>\n<span class=\"sd\">outputPrefix: Output File Prefix</span>\n<span class=\"sd\">::Output::</span>\n<span class=\"sd\">outputFile: File with following header</span>\n<span class=\"sd\">&quot;TumorId\\tNormalId\\tChr1\\tPos1\\tChr2\\tPos2\\tSV_Type\\tGene1\\tGene2\\tTranscript1\\tTranscript2\\tSite1Description\\tSite2Description\\tFusion\\tProbabilityScore\\tConfidence\\tComments\\tConnection_Type\\tSV_LENGTH\\tMAPQ\\tPairEndReadSupport\\tSplitReadSupport\\tBrkptType\\tConsensusSequence\\tTumorVariantCount\\tTumorSplitVariantCount\\tTumorReadCount\\tTumorGenotypeQScore\\tNormalVariantCount\\tNormalSplitVariantCount\\tNormalReadCount\\tNormalGenotypeQScorerepName-repClass-repFamily:-site1\\trepName-repClass-repFamily:-site2\\tCC_Chr_Band\\tCC_Tumour_Types(Somatic)\\tCC_Cancer_Syndrome\\tCC_Mutation_Type\\tCC_Translocation_Partner\\tDGv_Name-DGv_VarType-site1\\tDGv_Name-DGv_VarType-site2\\n&quot;;</span>\n<span class=\"sd\">&#39;&#39;&#39;</span>\n<span class=\"kn\">import</span> <span class=\"nn\">sys</span>\n<span class=\"kn\">import</span> <span class=\"nn\">os</span>\n<span class=\"kn\">import</span> <span class=\"nn\">logging</span>\n<span class=\"kn\">import</span> <span class=\"nn\">vcf</span>\n<span class=\"kn\">import</span> <span class=\"nn\">checkparameters</span> <span class=\"k\">as</span> <span class=\"nn\">cp</span>\n<span class=\"kn\">import</span> <span class=\"nn\">pandas</span> <span class=\"k\">as</span> <span class=\"nn\">pd</span>\n<span class=\"kn\">import</span> <span class=\"nn\">re</span>\n<span class=\"kn\">import</span> <span class=\"nn\">coloredlogs</span>\n<span class=\"kn\">import</span> <span class=\"nn\">numpy</span> <span class=\"k\">as</span> <span class=\"nn\">np</span>\n\n<span class=\"n\">logger</span> <span class=\"o\">=</span> <span class=\"n\">logging</span><span class=\"o\">.</span><span class=\"n\">getLogger</span><span class=\"p\">(</span><span class=\"s1\">&#39;iCallSV.mergeFinalFiles&#39;</span><span class=\"p\">)</span>\n<span class=\"n\">coloredlogs</span><span class=\"o\">.</span><span class=\"n\">install</span><span class=\"p\">(</span><span class=\"n\">level</span><span class=\"o\">=</span><span class=\"s1\">&#39;DEBUG&#39;</span><span class=\"p\">)</span>\n\n<div class=\"viewcode-block\" id=\"run\"><a class=\"viewcode-back\" href=\"../../../iCallSV/#iCallSV.mergeFinalFiles.run\">[docs]</a><span class=\"k\">def</span> <span class=\"nf\">run</span><span class=\"p\">(</span><span class=\"n\">aId</span><span class=\"p\">,</span> <span class=\"n\">bId</span><span class=\"p\">,</span> <span class=\"n\">vcfFile</span><span class=\"p\">,</span> <span class=\"n\">annoTab</span><span class=\"p\">,</span> <span class=\"n\">confTab</span><span class=\"p\">,</span> <span class=\"n\">outDir</span><span class=\"p\">,</span> <span class=\"n\">outputPrefix</span><span class=\"p\">,</span> <span class=\"n\">verbose</span><span class=\"p\">):</span>\n    <span class=\"sd\">&quot;&quot;&quot;</span>\n<span class=\"sd\">    This will Merge VCF, iAnnotateSV tab and targetSeqView tab file into a single tab-delimited file</span>\n\n<span class=\"sd\">    :param str aId: Sample ID for case that has the structural abberations</span>\n<span class=\"sd\">    :param str bId: Sample ID for control</span>\n<span class=\"sd\">    :param str vcfFile: Delly filtered and merged VCF file</span>\n<span class=\"sd\">    :param str annoTab: iAnnotateSV tab-delimited file with annotations</span>\n<span class=\"sd\">    :param str confTab: targetSeqView tab-delimited file with probability score</span>\n<span class=\"sd\">    :param str outputDir: Directory to write the output file</span>\n<span class=\"sd\">    :param str outputPrefix: Output File Prefix</span>\n<span class=\"sd\">    :return: str of the tab-delimited file</span>\n<span class=\"sd\">    :rtype: str</span>\n\n<span class=\"sd\">    &quot;&quot;&quot;</span>\n    <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"n\">verbose</span><span class=\"p\">):</span>\n        <span class=\"n\">logger</span><span class=\"o\">.</span><span class=\"n\">info</span><span class=\"p\">(</span>\n            <span class=\"s2\">&quot;iCallSV::MergeFinalFile: Merging Delly Filtered VCF, iAnnotateSV tab and targetSeqView tab file into a single tab-delimited file&quot;</span><span class=\"p\">)</span>\n    <span class=\"n\">cp</span><span class=\"o\">.</span><span class=\"n\">checkFile</span><span class=\"p\">(</span><span class=\"n\">vcfFile</span><span class=\"p\">)</span>\n    <span class=\"n\">cp</span><span class=\"o\">.</span><span class=\"n\">checkFile</span><span class=\"p\">(</span><span class=\"n\">annoTab</span><span class=\"p\">)</span>\n    <span class=\"c1\"># cp.checkFile(confTab)</span>\n    <span class=\"n\">cp</span><span class=\"o\">.</span><span class=\"n\">checkDir</span><span class=\"p\">(</span><span class=\"n\">outDir</span><span class=\"p\">)</span>\n    <span class=\"n\">outDF</span> <span class=\"o\">=</span> <span class=\"n\">pd</span><span class=\"o\">.</span><span class=\"n\">DataFrame</span><span class=\"p\">(</span>\n        <span class=\"n\">columns</span><span class=\"o\">=</span><span class=\"p\">[</span>\n            <span class=\"s2\">&quot;TumorId&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;NormalId&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Chr1&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Pos1&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Chr2&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Pos2&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;SV_Type&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Gene1&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Gene2&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Transcript1&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Transcript2&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Site1Description&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Site2Description&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Fusion&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;ProbabilityScore&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Confidence&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Comments&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Connection_Type&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;SV_LENGTH&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;MAPQ&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;PairEndReadSupport&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;SplitReadSupport&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;BrkptType&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;ConsensusSequence&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;TumorReferenceCount&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;TumorSplitReferenceCount&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;TumorVariantCount&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;TumorSplitVariantCount&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;TumorReadCount&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;TumorGenotypeQScore&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;NormalReferenceCount&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;NormalSplitReferenceCount&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;NormalVariantCount&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;NormalSplitVariantCount&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;NormalReadCount&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;NormalGenotypeQScore&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;Cosmic_Fusion_Counts&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;repName-repClass-repFamily:-site1&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;repName-repClass-repFamily:-site2&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;CC_Chr_Band&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;CC_Tumour_Types(Somatic)&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;CC_Cancer_Syndrome&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;CC_Mutation_Type&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;CC_Translocation_Partner&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;DGv_Name-DGv_VarType-site1&quot;</span><span class=\"p\">,</span>\n            <span class=\"s2\">&quot;DGv_Name-DGv_VarType-site2&quot;</span><span class=\"p\">])</span>\n    <span class=\"n\">annoDF</span> <span class=\"o\">=</span> <span class=\"n\">pd</span><span class=\"o\">.</span><span class=\"n\">read_csv</span><span class=\"p\">(</span><span class=\"n\">annoTab</span><span class=\"p\">,</span> <span class=\"n\">sep</span><span class=\"o\">=</span><span class=\"s2\">&quot;</span><span class=\"se\">\\t</span><span class=\"s2\">&quot;</span><span class=\"p\">,</span> <span class=\"n\">header</span><span class=\"o\">=</span><span class=\"mi\">0</span><span class=\"p\">,</span> <span class=\"n\">keep_default_na</span><span class=\"o\">=</span><span class=\"s1\">&#39;True&#39;</span><span class=\"p\">)</span>\n    <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"n\">os</span><span class=\"o\">.</span><span class=\"n\">path</span><span class=\"o\">.</span><span class=\"n\">isfile</span><span class=\"p\">(</span><span class=\"n\">confTab</span><span class=\"p\">)):</span>\n        <span class=\"n\">confDF</span> <span class=\"o\">=</span> <span class=\"n\">pd</span><span class=\"o\">.</span><span class=\"n\">read_csv</span><span class=\"p\">(</span><span class=\"n\">confTab</span><span class=\"p\">,</span> <span class=\"n\">sep</span><span class=\"o\">=</span><span class=\"s2\">&quot;</span><span class=\"se\">\\t</span><span class=\"s2\">&quot;</span><span class=\"p\">,</span> <span class=\"n\">header</span><span class=\"o\">=</span><span class=\"mi\">0</span><span class=\"p\">,</span> <span class=\"n\">keep_default_na</span><span class=\"o\">=</span><span class=\"s1\">&#39;True&#39;</span><span class=\"p\">)</span>\n    <span class=\"k\">else</span><span class=\"p\">:</span>\n        <span class=\"n\">confDF</span> <span class=\"o\">=</span> <span class=\"kc\">None</span>\n    <span class=\"c1\"># Read VCF and Traverse through it</span>\n    <span class=\"n\">vcf_reader</span> <span class=\"o\">=</span> <span class=\"n\">vcf</span><span class=\"o\">.</span><span class=\"n\">Reader</span><span class=\"p\">(</span><span class=\"nb\">open</span><span class=\"p\">(</span><span class=\"n\">vcfFile</span><span class=\"p\">,</span> <span class=\"s1\">&#39;r&#39;</span><span class=\"p\">))</span>\n    <span class=\"n\">samples</span> <span class=\"o\">=</span> <span class=\"n\">vcf_reader</span><span class=\"o\">.</span><span class=\"n\">samples</span>\n    <span class=\"n\">pattern</span> <span class=\"o\">=</span> <span class=\"n\">re</span><span class=\"o\">.</span><span class=\"n\">compile</span><span class=\"p\">(</span><span class=\"n\">aId</span><span class=\"p\">)</span>\n    <span class=\"c1\"># Get the case and control id</span>\n    <span class=\"n\">caseIDinVcf</span> <span class=\"o\">=</span> <span class=\"kc\">None</span>\n    <span class=\"n\">controlIDinVcf</span> <span class=\"o\">=</span> <span class=\"kc\">None</span>\n    <span class=\"k\">for</span> <span class=\"n\">sample</span> <span class=\"ow\">in</span> <span class=\"n\">samples</span><span class=\"p\">:</span>\n        <span class=\"n\">match</span> <span class=\"o\">=</span> <span class=\"n\">re</span><span class=\"o\">.</span><span class=\"n\">search</span><span class=\"p\">(</span><span class=\"n\">pattern</span><span class=\"p\">,</span> <span class=\"n\">sample</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"n\">match</span><span class=\"p\">):</span>\n            <span class=\"n\">caseIDinVcf</span> <span class=\"o\">=</span> <span class=\"n\">sample</span>\n        <span class=\"k\">else</span><span class=\"p\">:</span>\n            <span class=\"n\">controlIDinVcf</span> <span class=\"o\">=</span> <span class=\"n\">sample</span>\n    <span class=\"c1\"># traverse through the vcf</span>\n    <span class=\"n\">count</span> <span class=\"o\">=</span> <span class=\"mi\">0</span>\n    <span class=\"k\">for</span> <span class=\"n\">record</span> <span class=\"ow\">in</span> <span class=\"n\">vcf_reader</span><span class=\"p\">:</span>\n        <span class=\"c1\"># Define all variables:</span>\n        <span class=\"p\">(</span><span class=\"n\">chrom1</span><span class=\"p\">,</span>\n         <span class=\"n\">start1</span><span class=\"p\">,</span>\n         <span class=\"n\">start2</span><span class=\"p\">,</span>\n         <span class=\"n\">chrom2</span><span class=\"p\">,</span>\n         <span class=\"nb\">filter</span><span class=\"p\">,</span>\n         <span class=\"n\">svtype</span><span class=\"p\">,</span>\n         <span class=\"n\">brktype</span><span class=\"p\">,</span>\n         <span class=\"n\">contype</span><span class=\"p\">,</span>\n         <span class=\"n\">conseq</span><span class=\"p\">)</span> <span class=\"o\">=</span> <span class=\"p\">(</span><span class=\"kc\">None</span> <span class=\"k\">for</span> <span class=\"n\">i</span> <span class=\"ow\">in</span> <span class=\"nb\">range</span><span class=\"p\">(</span><span class=\"mi\">9</span><span class=\"p\">))</span>\n         \n        <span class=\"p\">(</span><span class=\"n\">startCT</span><span class=\"p\">,</span>\n         <span class=\"n\">endCT</span><span class=\"p\">,</span>\n         <span class=\"n\">str1</span><span class=\"p\">,</span>\n         <span class=\"n\">str2</span><span class=\"p\">,</span>\n         <span class=\"n\">svlengthFromDelly</span><span class=\"p\">,</span>\n         <span class=\"n\">mapqFromDelly</span><span class=\"p\">,</span>\n         <span class=\"n\">peSupportFromDelly</span><span class=\"p\">,</span>\n         <span class=\"n\">srSupportFromDelly</span><span class=\"p\">,</span>\n         <span class=\"n\">ciEndNeg</span><span class=\"p\">,</span>\n         <span class=\"n\">ciEndPos</span><span class=\"p\">,</span>\n         <span class=\"n\">ciPosNeg</span><span class=\"p\">,</span>\n         <span class=\"n\">ciPosPos</span><span class=\"p\">,</span>\n         <span class=\"n\">caseRC</span><span class=\"p\">,</span>\n         <span class=\"n\">caseGQ</span><span class=\"p\">,</span>\n         <span class=\"n\">caseDR</span><span class=\"p\">,</span>\n         <span class=\"n\">caseDV</span><span class=\"p\">,</span>\n         <span class=\"n\">caseRR</span><span class=\"p\">,</span>\n         <span class=\"n\">caseRV</span><span class=\"p\">,</span>\n         <span class=\"n\">controlGQ</span><span class=\"p\">,</span>\n         <span class=\"n\">controlRC</span><span class=\"p\">,</span>\n         <span class=\"n\">controlDR</span><span class=\"p\">,</span>\n         <span class=\"n\">controlDV</span><span class=\"p\">,</span>\n         <span class=\"n\">controlRR</span><span class=\"p\">,</span>\n         <span class=\"n\">controlRV</span><span class=\"p\">)</span> <span class=\"o\">=</span> <span class=\"p\">(</span><span class=\"mi\">0</span> <span class=\"k\">for</span> <span class=\"n\">i</span> <span class=\"ow\">in</span> <span class=\"nb\">range</span><span class=\"p\">(</span><span class=\"mi\">24</span><span class=\"p\">))</span>\n        <span class=\"n\">chrom1</span> <span class=\"o\">=</span> <span class=\"nb\">str</span><span class=\"p\">(</span><span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">CHROM</span><span class=\"p\">)</span>\n        <span class=\"n\">start1</span> <span class=\"o\">=</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">POS</span>\n        <span class=\"nb\">filter</span> <span class=\"o\">=</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">FILTER</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">len</span><span class=\"p\">(</span><span class=\"nb\">filter</span><span class=\"p\">)</span> <span class=\"o\">&lt;</span> <span class=\"mi\">1</span><span class=\"p\">):</span>\n            <span class=\"nb\">filter</span> <span class=\"o\">=</span> <span class=\"kc\">None</span>\n        <span class=\"k\">else</span><span class=\"p\">:</span>\n            <span class=\"nb\">filter</span> <span class=\"o\">=</span> <span class=\"nb\">filter</span><span class=\"p\">[</span><span class=\"mi\">0</span><span class=\"p\">]</span>\n        <span class=\"n\">preciseFlag</span> <span class=\"o\">=</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">is_sv_precise</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"s2\">&quot;END&quot;</span> <span class=\"ow\">in</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">):</span>\n            <span class=\"n\">start2</span> <span class=\"o\">=</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">[</span><span class=\"s1\">&#39;END&#39;</span><span class=\"p\">]</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"s2\">&quot;CHR2&quot;</span> <span class=\"ow\">in</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">):</span>\n            <span class=\"n\">chrom2</span> <span class=\"o\">=</span> <span class=\"nb\">str</span><span class=\"p\">(</span><span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">[</span><span class=\"s1\">&#39;CHR2&#39;</span><span class=\"p\">])</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"s2\">&quot;SVTYPE&quot;</span> <span class=\"ow\">in</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">):</span>\n            <span class=\"n\">svtype</span> <span class=\"o\">=</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">[</span><span class=\"s1\">&#39;SVTYPE&#39;</span><span class=\"p\">]</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"s2\">&quot;SVLEN&quot;</span> <span class=\"ow\">in</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">):</span>\n            <span class=\"n\">svlengthFromDelly</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">[</span><span class=\"s1\">&#39;SVLEN&#39;</span><span class=\"p\">])</span>\n        <span class=\"k\">else</span><span class=\"p\">:</span>\n            <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"n\">svtype</span> <span class=\"o\">==</span> <span class=\"s2\">&quot;TRA&quot;</span><span class=\"p\">):</span>\n                <span class=\"n\">svlengthFromDelly</span> <span class=\"o\">=</span> <span class=\"mi\">0</span>\n            <span class=\"k\">else</span><span class=\"p\">:</span>\n                <span class=\"n\">svlengthFromDelly</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"nb\">abs</span><span class=\"p\">(</span><span class=\"n\">start2</span> <span class=\"o\">-</span> <span class=\"n\">start1</span><span class=\"p\">))</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"s2\">&quot;MAPQ&quot;</span> <span class=\"ow\">in</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">):</span>\n            <span class=\"n\">mapqFromDelly</span> <span class=\"o\">=</span>  <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">[</span><span class=\"s1\">&#39;MAPQ&#39;</span><span class=\"p\">])</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"s2\">&quot;PE&quot;</span> <span class=\"ow\">in</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">):</span>\n            <span class=\"n\">peSupportFromDelly</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">[</span><span class=\"s1\">&#39;PE&#39;</span><span class=\"p\">])</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"s2\">&quot;SR&quot;</span> <span class=\"ow\">in</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">):</span>\n            <span class=\"n\">srSupportFromDelly</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">[</span><span class=\"s1\">&#39;SR&#39;</span><span class=\"p\">])</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"s2\">&quot;CT&quot;</span> <span class=\"ow\">in</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">):</span>\n            <span class=\"n\">contype</span> <span class=\"o\">=</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">[</span><span class=\"s1\">&#39;CT&#39;</span><span class=\"p\">]</span>\n        <span class=\"p\">(</span><span class=\"n\">startCT</span><span class=\"p\">,</span> <span class=\"n\">endCT</span><span class=\"p\">)</span> <span class=\"o\">=</span> <span class=\"n\">contype</span><span class=\"o\">.</span><span class=\"n\">split</span><span class=\"p\">(</span><span class=\"s2\">&quot;to&quot;</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span><span class=\"p\">((</span><span class=\"nb\">int</span><span class=\"p\">(</span><span class=\"n\">startCT</span><span class=\"p\">)</span> <span class=\"o\">==</span> <span class=\"mi\">3</span><span class=\"p\">)</span> <span class=\"ow\">and</span> <span class=\"p\">(</span><span class=\"nb\">int</span><span class=\"p\">(</span><span class=\"n\">endCT</span><span class=\"p\">)</span> <span class=\"o\">==</span> <span class=\"mi\">3</span><span class=\"p\">)):</span>\n            <span class=\"n\">str1</span> <span class=\"o\">=</span> <span class=\"mi\">0</span>\n            <span class=\"n\">str2</span> <span class=\"o\">=</span> <span class=\"mi\">0</span>\n        <span class=\"k\">elif</span><span class=\"p\">((</span><span class=\"nb\">int</span><span class=\"p\">(</span><span class=\"n\">startCT</span><span class=\"p\">)</span> <span class=\"o\">==</span> <span class=\"mi\">3</span><span class=\"p\">)</span> <span class=\"ow\">and</span> <span class=\"p\">(</span><span class=\"nb\">int</span><span class=\"p\">(</span><span class=\"n\">endCT</span><span class=\"p\">)</span> <span class=\"o\">==</span> <span class=\"mi\">5</span><span class=\"p\">)):</span>\n            <span class=\"n\">str1</span> <span class=\"o\">=</span> <span class=\"mi\">0</span>\n            <span class=\"n\">str2</span> <span class=\"o\">=</span> <span class=\"mi\">1</span>\n        <span class=\"k\">elif</span><span class=\"p\">((</span><span class=\"nb\">int</span><span class=\"p\">(</span><span class=\"n\">startCT</span><span class=\"p\">)</span> <span class=\"o\">==</span> <span class=\"mi\">5</span><span class=\"p\">)</span> <span class=\"ow\">and</span> <span class=\"p\">(</span><span class=\"nb\">int</span><span class=\"p\">(</span><span class=\"n\">endCT</span><span class=\"p\">)</span> <span class=\"o\">==</span> <span class=\"mi\">3</span><span class=\"p\">)):</span>\n            <span class=\"n\">str1</span> <span class=\"o\">=</span> <span class=\"mi\">1</span>\n            <span class=\"n\">str2</span> <span class=\"o\">=</span> <span class=\"mi\">0</span>\n        <span class=\"k\">elif</span><span class=\"p\">((</span><span class=\"nb\">int</span><span class=\"p\">(</span><span class=\"n\">startCT</span><span class=\"p\">)</span> <span class=\"o\">==</span> <span class=\"mi\">5</span><span class=\"p\">)</span> <span class=\"ow\">and</span> <span class=\"p\">(</span><span class=\"nb\">int</span><span class=\"p\">(</span><span class=\"n\">endCT</span><span class=\"p\">)</span> <span class=\"o\">==</span> <span class=\"mi\">5</span><span class=\"p\">)):</span>\n            <span class=\"n\">str1</span> <span class=\"o\">=</span> <span class=\"mi\">1</span>\n            <span class=\"n\">str2</span> <span class=\"o\">=</span> <span class=\"mi\">1</span>\n        <span class=\"k\">else</span><span class=\"p\">:</span>\n            <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"n\">verbose</span><span class=\"p\">):</span>\n                <span class=\"n\">logger</span><span class=\"o\">.</span><span class=\"n\">warning</span><span class=\"p\">(</span>\n                    <span class=\"s2\">&quot;mergeFinalFiles: The connection type (CT) given in the vcf file is incorrect.CT: </span><span class=\"si\">%s</span><span class=\"s2\">&quot;</span><span class=\"p\">,</span>\n                    <span class=\"n\">contype</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"s2\">&quot;CONSENSUS&quot;</span> <span class=\"ow\">in</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">):</span>\n            <span class=\"n\">conseq</span> <span class=\"o\">=</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">[</span><span class=\"s1\">&#39;CONSENSUS&#39;</span><span class=\"p\">]</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">is_sv_precise</span><span class=\"p\">):</span>\n            <span class=\"n\">brktype</span> <span class=\"o\">=</span> <span class=\"s2\">&quot;PRECISE&quot;</span>\n        <span class=\"k\">else</span><span class=\"p\">:</span>\n            <span class=\"n\">brktype</span> <span class=\"o\">=</span> <span class=\"s2\">&quot;IMPPRECISE&quot;</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"s2\">&quot;CIEND&quot;</span> <span class=\"ow\">in</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">):</span>\n            <span class=\"n\">ciEndNeg</span><span class=\"p\">,</span> <span class=\"n\">ciEndPos</span> <span class=\"o\">=</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">[</span><span class=\"s1\">&#39;CIEND&#39;</span><span class=\"p\">]</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">abs</span><span class=\"p\">(</span><span class=\"n\">ciEndNeg</span><span class=\"p\">)</span> <span class=\"o\">&lt;</span> <span class=\"mi\">50</span><span class=\"p\">):</span>\n            <span class=\"n\">ciEndNeg</span> <span class=\"o\">=</span> <span class=\"mi\">50</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">abs</span><span class=\"p\">(</span><span class=\"n\">ciEndPos</span><span class=\"p\">)</span> <span class=\"o\">&lt;</span> <span class=\"mi\">50</span><span class=\"p\">):</span>\n            <span class=\"n\">ciEndNeg</span> <span class=\"o\">=</span> <span class=\"mi\">50</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"s2\">&quot;CIPOS&quot;</span> <span class=\"ow\">in</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">):</span>\n            <span class=\"n\">ciPosNeg</span><span class=\"p\">,</span> <span class=\"n\">ciPosPos</span> <span class=\"o\">=</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">INFO</span><span class=\"p\">[</span><span class=\"s1\">&#39;CIPOS&#39;</span><span class=\"p\">]</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">abs</span><span class=\"p\">(</span><span class=\"n\">ciPosNeg</span><span class=\"p\">)</span> <span class=\"o\">&lt;</span> <span class=\"mi\">50</span><span class=\"p\">):</span>\n            <span class=\"n\">ciPosNeg</span> <span class=\"o\">=</span> <span class=\"mi\">50</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">abs</span><span class=\"p\">(</span><span class=\"n\">ciPosPos</span><span class=\"p\">)</span> <span class=\"o\">&lt;</span> <span class=\"mi\">50</span><span class=\"p\">):</span>\n            <span class=\"n\">ciPosNeg</span> <span class=\"o\">=</span> <span class=\"mi\">50</span>\n\n        <span class=\"n\">caseCalls</span> <span class=\"o\">=</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">genotype</span><span class=\"p\">(</span><span class=\"n\">caseIDinVcf</span><span class=\"p\">)</span>\n        <span class=\"n\">controlCalls</span> <span class=\"o\">=</span> <span class=\"n\">record</span><span class=\"o\">.</span><span class=\"n\">genotype</span><span class=\"p\">(</span><span class=\"n\">controlIDinVcf</span><span class=\"p\">)</span>\n\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">hasattr</span><span class=\"p\">(</span><span class=\"n\">caseCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"p\">,</span> <span class=\"s2\">&quot;GQ&quot;</span><span class=\"p\">)):</span>\n            <span class=\"n\">caseGQ</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">caseCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"o\">.</span><span class=\"n\">GQ</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">hasattr</span><span class=\"p\">(</span><span class=\"n\">caseCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"p\">,</span> <span class=\"s2\">&quot;RC&quot;</span><span class=\"p\">)):</span>\n            <span class=\"n\">caseRC</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">caseCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"o\">.</span><span class=\"n\">RC</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">hasattr</span><span class=\"p\">(</span><span class=\"n\">caseCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"p\">,</span> <span class=\"s2\">&quot;DR&quot;</span><span class=\"p\">)):</span>\n            <span class=\"n\">caseDR</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">caseCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"o\">.</span><span class=\"n\">DR</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">hasattr</span><span class=\"p\">(</span><span class=\"n\">caseCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"p\">,</span> <span class=\"s2\">&quot;DV&quot;</span><span class=\"p\">)):</span>\n            <span class=\"n\">caseDV</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">caseCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"o\">.</span><span class=\"n\">DV</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">hasattr</span><span class=\"p\">(</span><span class=\"n\">caseCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"p\">,</span> <span class=\"s2\">&quot;RR&quot;</span><span class=\"p\">)):</span>\n            <span class=\"n\">caseRR</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">caseCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"o\">.</span><span class=\"n\">RR</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">hasattr</span><span class=\"p\">(</span><span class=\"n\">caseCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"p\">,</span> <span class=\"s2\">&quot;RV&quot;</span><span class=\"p\">)):</span>\n            <span class=\"n\">caseRV</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">caseCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"o\">.</span><span class=\"n\">RV</span><span class=\"p\">)</span>\n\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">hasattr</span><span class=\"p\">(</span><span class=\"n\">controlCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"p\">,</span> <span class=\"s2\">&quot;GQ&quot;</span><span class=\"p\">)):</span>\n            <span class=\"n\">controlGQ</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">controlCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"o\">.</span><span class=\"n\">GQ</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">hasattr</span><span class=\"p\">(</span><span class=\"n\">controlCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"p\">,</span> <span class=\"s2\">&quot;RC&quot;</span><span class=\"p\">)):</span>\n            <span class=\"n\">controlRC</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">controlCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"o\">.</span><span class=\"n\">RC</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">hasattr</span><span class=\"p\">(</span><span class=\"n\">controlCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"p\">,</span> <span class=\"s2\">&quot;DR&quot;</span><span class=\"p\">)):</span>\n            <span class=\"n\">controlDR</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">controlCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"o\">.</span><span class=\"n\">DR</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">hasattr</span><span class=\"p\">(</span><span class=\"n\">controlCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"p\">,</span> <span class=\"s2\">&quot;DV&quot;</span><span class=\"p\">)):</span>\n            <span class=\"n\">controlDV</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">controlCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"o\">.</span><span class=\"n\">DV</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">hasattr</span><span class=\"p\">(</span><span class=\"n\">controlCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"p\">,</span> <span class=\"s2\">&quot;RR&quot;</span><span class=\"p\">)):</span>\n            <span class=\"n\">controlRR</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">controlCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"o\">.</span><span class=\"n\">RR</span><span class=\"p\">)</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">hasattr</span><span class=\"p\">(</span><span class=\"n\">controlCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"p\">,</span> <span class=\"s2\">&quot;RV&quot;</span><span class=\"p\">)):</span>\n            <span class=\"n\">controlRV</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">int</span><span class=\"p\">(</span><span class=\"n\">controlCalls</span><span class=\"o\">.</span><span class=\"n\">data</span><span class=\"o\">.</span><span class=\"n\">RV</span><span class=\"p\">)</span>\n\n        <span class=\"c1\"># Get data from annotation file</span>\n        <span class=\"p\">(</span><span class=\"n\">indexList</span><span class=\"p\">,</span>\n         <span class=\"n\">annoIndex</span><span class=\"p\">,</span>\n         <span class=\"n\">gene1</span><span class=\"p\">,</span>\n         <span class=\"n\">gene2</span><span class=\"p\">,</span>\n         <span class=\"n\">transcript1</span><span class=\"p\">,</span>\n         <span class=\"n\">transcript2</span><span class=\"p\">,</span>\n         <span class=\"n\">site1</span><span class=\"p\">,</span>\n         <span class=\"n\">site2</span><span class=\"p\">,</span>\n         <span class=\"n\">fusion</span><span class=\"p\">,</span>\n         <span class=\"n\">rr_site1</span><span class=\"p\">,</span>\n         <span class=\"n\">rr_site2</span><span class=\"p\">,</span>\n         <span class=\"n\">cc_chr_band</span><span class=\"p\">,</span>\n         <span class=\"n\">cc_t_t</span><span class=\"p\">,</span>\n         <span class=\"n\">cc_c_s</span><span class=\"p\">,</span>\n         <span class=\"n\">cc_m_t</span><span class=\"p\">,</span>\n         <span class=\"n\">cc_t_p</span><span class=\"p\">,</span>\n         <span class=\"n\">dgv_site1</span><span class=\"p\">,</span>\n         <span class=\"n\">dgv_site2</span>\n         <span class=\"p\">)</span> <span class=\"o\">=</span> <span class=\"p\">(</span><span class=\"kc\">None</span> <span class=\"k\">for</span> <span class=\"n\">i</span> <span class=\"ow\">in</span> <span class=\"nb\">range</span><span class=\"p\">(</span><span class=\"mi\">18</span><span class=\"p\">))</span>\n        <span class=\"n\">cosmic_fusion_counts</span> <span class=\"o\">=</span> <span class=\"mi\">0</span>\n\n        <span class=\"n\">annoDF</span><span class=\"p\">[[</span><span class=\"s1\">&#39;chr1&#39;</span><span class=\"p\">,</span> <span class=\"s1\">&#39;chr2&#39;</span><span class=\"p\">]]</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"p\">[[</span><span class=\"s1\">&#39;chr1&#39;</span><span class=\"p\">,</span> <span class=\"s1\">&#39;chr2&#39;</span><span class=\"p\">]]</span><span class=\"o\">.</span><span class=\"n\">astype</span><span class=\"p\">(</span><span class=\"nb\">str</span><span class=\"p\">)</span>\n        <span class=\"n\">annoDF</span><span class=\"p\">[</span><span class=\"s1\">&#39;Cosmic_Fusion_Counts&#39;</span><span class=\"p\">]</span><span class=\"o\">.</span><span class=\"n\">fillna</span><span class=\"p\">(</span><span class=\"mi\">0</span><span class=\"p\">,</span> <span class=\"n\">inplace</span><span class=\"o\">=</span><span class=\"kc\">True</span><span class=\"p\">)</span>\n        <span class=\"n\">annoDF</span><span class=\"p\">[[</span><span class=\"s1\">&#39;Cosmic_Fusion_Counts&#39;</span><span class=\"p\">]]</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"p\">[[</span><span class=\"s1\">&#39;Cosmic_Fusion_Counts&#39;</span><span class=\"p\">]]</span><span class=\"o\">.</span><span class=\"n\">astype</span><span class=\"p\">(</span><span class=\"nb\">int</span><span class=\"p\">)</span>\n        <span class=\"n\">indexList</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">loc</span><span class=\"p\">[</span><span class=\"n\">annoDF</span><span class=\"p\">[</span><span class=\"s1\">&#39;chr1&#39;</span><span class=\"p\">]</span><span class=\"o\">.</span><span class=\"n\">isin</span><span class=\"p\">([</span><span class=\"n\">chrom1</span><span class=\"p\">])</span> <span class=\"o\">&amp;</span>\n                               <span class=\"n\">annoDF</span><span class=\"p\">[</span><span class=\"s1\">&#39;pos1&#39;</span><span class=\"p\">]</span><span class=\"o\">.</span><span class=\"n\">isin</span><span class=\"p\">([</span><span class=\"nb\">int</span><span class=\"p\">(</span><span class=\"n\">start1</span><span class=\"p\">)])</span> <span class=\"o\">&amp;</span>\n                               <span class=\"n\">annoDF</span><span class=\"p\">[</span><span class=\"s1\">&#39;chr2&#39;</span><span class=\"p\">]</span><span class=\"o\">.</span><span class=\"n\">isin</span><span class=\"p\">([</span><span class=\"n\">chrom2</span><span class=\"p\">])</span> <span class=\"o\">&amp;</span>\n                               <span class=\"n\">annoDF</span><span class=\"p\">[</span><span class=\"s1\">&#39;pos2&#39;</span><span class=\"p\">]</span><span class=\"o\">.</span><span class=\"n\">isin</span><span class=\"p\">([</span><span class=\"nb\">int</span><span class=\"p\">(</span><span class=\"n\">start2</span><span class=\"p\">)])</span> <span class=\"o\">&amp;</span> \n                               <span class=\"n\">annoDF</span><span class=\"p\">[</span><span class=\"s1\">&#39;str1&#39;</span><span class=\"p\">]</span><span class=\"o\">.</span><span class=\"n\">isin</span><span class=\"p\">([</span><span class=\"n\">str1</span><span class=\"p\">])</span> <span class=\"o\">&amp;</span>\n                               <span class=\"n\">annoDF</span><span class=\"p\">[</span><span class=\"s1\">&#39;str2&#39;</span><span class=\"p\">]</span><span class=\"o\">.</span><span class=\"n\">isin</span><span class=\"p\">([</span><span class=\"n\">str2</span><span class=\"p\">])]</span><span class=\"o\">.</span><span class=\"n\">index</span><span class=\"o\">.</span><span class=\"n\">tolist</span><span class=\"p\">()</span>\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">len</span><span class=\"p\">(</span><span class=\"n\">indexList</span><span class=\"p\">)</span> <span class=\"o\">&gt;</span> <span class=\"mi\">1</span><span class=\"p\">):</span>\n            <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"n\">verbose</span><span class=\"p\">):</span>\n                <span class=\"n\">logger</span><span class=\"o\">.</span><span class=\"n\">fatal</span><span class=\"p\">(</span>\n                    <span class=\"s2\">&quot;iCallSV::MergeFinalFile: More then one sv have same coordinate in same sample for annotated file. Please check and rerun&quot;</span><span class=\"p\">)</span>\n            <span class=\"n\">sys</span><span class=\"o\">.</span><span class=\"n\">exit</span><span class=\"p\">(</span><span class=\"mi\">1</span><span class=\"p\">)</span>\n        <span class=\"k\">else</span><span class=\"p\">:</span>\n            <span class=\"n\">annoIndex</span> <span class=\"o\">=</span> <span class=\"n\">indexList</span><span class=\"p\">[</span><span class=\"mi\">0</span><span class=\"p\">]</span>\n\n        <span class=\"n\">gene1</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;gene1&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">gene2</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;gene2&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">transcript1</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;transcript1&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">transcript2</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;transcript2&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">site1</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;site1&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">site2</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;site2&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">fusion</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;fusion&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">rr_site1</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;repName-repClass-repFamily:-site1&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">rr_site2</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;repName-repClass-repFamily:-site2&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">cosmic_fusion_counts</span> <span class=\"o\">=</span> <span class=\"nb\">int</span><span class=\"p\">(</span><span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;Cosmic_Fusion_Counts&#39;</span><span class=\"p\">])</span>\n        <span class=\"n\">cc_chr_band</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;CC_Chr_Band&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">cc_t_t</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;CC_Tumour_Types(Somatic)&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">cc_c_s</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;CC_Cancer_Syndrome&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">cc_m_t</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;CC_Mutation_Type&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">cc_t_p</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;CC_Translocation_Partner&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">dgv_site1</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;DGv_Name-DGv_VarType-site1&#39;</span><span class=\"p\">]</span>\n        <span class=\"n\">dgv_site2</span> <span class=\"o\">=</span> <span class=\"n\">annoDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">annoIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;DGv_Name-DGv_VarType-site2&#39;</span><span class=\"p\">]</span>\n\n        <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"n\">confDF</span> <span class=\"ow\">is</span> <span class=\"kc\">None</span><span class=\"p\">):</span>\n            <span class=\"n\">confidenceScore</span> <span class=\"o\">=</span> <span class=\"kc\">None</span>\n        <span class=\"k\">else</span><span class=\"p\">:</span>\n            <span class=\"c1\"># Get information for confidence score</span>\n            <span class=\"n\">confIndex</span> <span class=\"o\">=</span> <span class=\"kc\">None</span>\n            <span class=\"n\">confidenceScore</span> <span class=\"o\">=</span> <span class=\"kc\">None</span>\n            <span class=\"n\">confDF</span><span class=\"p\">[[</span><span class=\"s1\">&#39;Chr1&#39;</span><span class=\"p\">,</span> <span class=\"s1\">&#39;Chr2&#39;</span><span class=\"p\">]]</span> <span class=\"o\">=</span> <span class=\"n\">confDF</span><span class=\"p\">[[</span><span class=\"s1\">&#39;Chr1&#39;</span><span class=\"p\">,</span> <span class=\"s1\">&#39;Chr2&#39;</span><span class=\"p\">]]</span><span class=\"o\">.</span><span class=\"n\">astype</span><span class=\"p\">(</span><span class=\"nb\">str</span><span class=\"p\">)</span>\n            <span class=\"n\">indexList</span> <span class=\"o\">=</span> <span class=\"n\">confDF</span><span class=\"o\">.</span><span class=\"n\">loc</span><span class=\"p\">[</span>\n                <span class=\"n\">confDF</span><span class=\"p\">[</span><span class=\"s1\">&#39;Chr1&#39;</span><span class=\"p\">]</span><span class=\"o\">.</span><span class=\"n\">isin</span><span class=\"p\">([</span><span class=\"n\">chrom1</span><span class=\"p\">])</span> <span class=\"o\">&amp;</span> <span class=\"n\">confDF</span><span class=\"p\">[</span><span class=\"s1\">&#39;Start1&#39;</span><span class=\"p\">]</span><span class=\"o\">.</span><span class=\"n\">isin</span><span class=\"p\">(</span>\n                    <span class=\"p\">[</span><span class=\"nb\">int</span><span class=\"p\">(</span><span class=\"n\">start1</span> <span class=\"o\">-</span> <span class=\"nb\">abs</span><span class=\"p\">(</span><span class=\"n\">ciPosNeg</span><span class=\"p\">))])</span> <span class=\"o\">&amp;</span> <span class=\"n\">confDF</span><span class=\"p\">[</span><span class=\"s1\">&#39;Chr2&#39;</span><span class=\"p\">]</span><span class=\"o\">.</span><span class=\"n\">isin</span><span class=\"p\">([</span><span class=\"n\">chrom2</span><span class=\"p\">])</span> <span class=\"o\">&amp;</span>\n                <span class=\"n\">confDF</span><span class=\"p\">[</span><span class=\"s1\">&#39;Start2&#39;</span><span class=\"p\">]</span><span class=\"o\">.</span><span class=\"n\">isin</span><span class=\"p\">([</span><span class=\"nb\">int</span><span class=\"p\">(</span><span class=\"n\">start2</span> <span class=\"o\">-</span> <span class=\"nb\">abs</span><span class=\"p\">(</span><span class=\"n\">ciEndNeg</span><span class=\"p\">))])]</span><span class=\"o\">.</span><span class=\"n\">index</span><span class=\"o\">.</span><span class=\"n\">tolist</span><span class=\"p\">()</span>\n\n            <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"nb\">len</span><span class=\"p\">(</span><span class=\"n\">indexList</span><span class=\"p\">)</span> <span class=\"o\">&gt;</span> <span class=\"mi\">1</span><span class=\"p\">):</span>\n                <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"n\">verbose</span><span class=\"p\">):</span>\n                    <span class=\"n\">logger</span><span class=\"o\">.</span><span class=\"n\">fatal</span><span class=\"p\">(</span>\n                        <span class=\"s2\">&quot;iCallSV::MergeFinalFile: More then one sv have same coordinate in same sample for confidence score. Please check and rerun&quot;</span><span class=\"p\">)</span>\n                <span class=\"n\">sys</span><span class=\"o\">.</span><span class=\"n\">exit</span><span class=\"p\">(</span><span class=\"mi\">1</span><span class=\"p\">)</span>\n            <span class=\"k\">else</span><span class=\"p\">:</span>\n                <span class=\"n\">confIndex</span> <span class=\"o\">=</span> <span class=\"n\">indexList</span><span class=\"p\">[</span><span class=\"mi\">0</span><span class=\"p\">]</span>\n            <span class=\"n\">confidenceScore</span> <span class=\"o\">=</span> <span class=\"n\">np</span><span class=\"o\">.</span><span class=\"n\">float</span><span class=\"p\">(</span><span class=\"n\">confDF</span><span class=\"o\">.</span><span class=\"n\">iloc</span><span class=\"p\">[</span><span class=\"n\">confIndex</span><span class=\"p\">][</span><span class=\"s1\">&#39;ProbabilityScore&#39;</span><span class=\"p\">])</span>\n\n        <span class=\"c1\"># populate final dataframe</span>\n        <span class=\"n\">outDF</span><span class=\"o\">.</span><span class=\"n\">loc</span><span class=\"p\">[</span><span class=\"n\">count</span><span class=\"p\">,</span>\n                  <span class=\"p\">[</span><span class=\"s2\">&quot;TumorId&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;NormalId&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;Chr1&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;Pos1&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;Chr2&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;Pos2&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;SV_Type&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;Gene1&quot;</span><span class=\"p\">,</span>\n                   <span class=\"s2\">&quot;Gene2&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;Transcript1&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;Transcript2&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;Site1Description&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;Site2Description&quot;</span><span class=\"p\">,</span>\n                   <span class=\"s2\">&quot;Fusion&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;ProbabilityScore&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;Confidence&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;Comments&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;Connection_Type&quot;</span><span class=\"p\">,</span>\n                   <span class=\"s2\">&quot;SV_LENGTH&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;MAPQ&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;PairEndReadSupport&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;SplitReadSupport&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;BrkptType&quot;</span><span class=\"p\">,</span>\n                   <span class=\"s2\">&quot;ConsensusSequence&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;TumorReferenceCount&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;TumorSplitReferenceCount&quot;</span><span class=\"p\">,</span>\n                   <span class=\"s2\">&quot;TumorVariantCount&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;TumorSplitVariantCount&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;TumorReadCount&quot;</span><span class=\"p\">,</span>\n                   <span class=\"s2\">&quot;TumorGenotypeQScore&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;NormalReferenceCount&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;NormalSplitReferenceCount&quot;</span><span class=\"p\">,</span>\n                   <span class=\"s2\">&quot;NormalVariantCount&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;NormalSplitVariantCount&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;NormalReadCount&quot;</span><span class=\"p\">,</span>\n                   <span class=\"s2\">&quot;NormalGenotypeQScore&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;Cosmic_Fusion_Counts&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;repName-repClass-repFamily:-site1&quot;</span><span class=\"p\">,</span>\n                   <span class=\"s2\">&quot;repName-repClass-repFamily:-site2&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;CC_Chr_Band&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;CC_Tumour_Types(Somatic)&quot;</span><span class=\"p\">,</span>\n                   <span class=\"s2\">&quot;CC_Cancer_Syndrome&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;CC_Mutation_Type&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;CC_Translocation_Partner&quot;</span><span class=\"p\">,</span>\n                   <span class=\"s2\">&quot;DGv_Name-DGv_VarType-site1&quot;</span><span class=\"p\">,</span> <span class=\"s2\">&quot;DGv_Name-DGv_VarType-site2&quot;</span><span class=\"p\">]]</span> <span class=\"o\">=</span> <span class=\"p\">[</span><span class=\"n\">aId</span><span class=\"p\">,</span> <span class=\"n\">bId</span><span class=\"p\">,</span> <span class=\"n\">chrom1</span><span class=\"p\">,</span>\n                                                                                   <span class=\"n\">start1</span><span class=\"p\">,</span> <span class=\"n\">chrom2</span><span class=\"p\">,</span> <span class=\"n\">start2</span><span class=\"p\">,</span> <span class=\"n\">svtype</span><span class=\"p\">,</span> <span class=\"n\">gene1</span><span class=\"p\">,</span> <span class=\"n\">gene2</span><span class=\"p\">,</span> <span class=\"n\">transcript1</span><span class=\"p\">,</span> <span class=\"n\">transcript2</span><span class=\"p\">,</span> <span class=\"n\">site1</span><span class=\"p\">,</span> <span class=\"n\">site2</span><span class=\"p\">,</span>\n                                                                                   <span class=\"n\">fusion</span><span class=\"p\">,</span> <span class=\"n\">confidenceScore</span><span class=\"p\">,</span> <span class=\"kc\">None</span><span class=\"p\">,</span> <span class=\"kc\">None</span><span class=\"p\">,</span> <span class=\"n\">contype</span><span class=\"p\">,</span> <span class=\"n\">svlengthFromDelly</span><span class=\"p\">,</span> <span class=\"n\">mapqFromDelly</span><span class=\"p\">,</span>\n                                                                                   <span class=\"n\">peSupportFromDelly</span><span class=\"p\">,</span> <span class=\"n\">srSupportFromDelly</span><span class=\"p\">,</span> <span class=\"n\">brktype</span><span class=\"p\">,</span> <span class=\"n\">conseq</span><span class=\"p\">,</span> <span class=\"n\">caseDR</span><span class=\"p\">,</span> <span class=\"n\">caseRR</span><span class=\"p\">,</span> <span class=\"n\">caseDV</span><span class=\"p\">,</span> <span class=\"n\">caseRV</span><span class=\"p\">,</span>\n                                                                                   <span class=\"n\">caseRC</span><span class=\"p\">,</span> <span class=\"n\">caseGQ</span><span class=\"p\">,</span> <span class=\"n\">controlDR</span><span class=\"p\">,</span> <span class=\"n\">controlRR</span><span class=\"p\">,</span> <span class=\"n\">controlDV</span><span class=\"p\">,</span> <span class=\"n\">controlRV</span><span class=\"p\">,</span> <span class=\"n\">controlRC</span><span class=\"p\">,</span> <span class=\"n\">controlGQ</span><span class=\"p\">,</span> <span class=\"n\">cosmic_fusion_counts</span><span class=\"p\">,</span>\n                                                                                   <span class=\"n\">rr_site1</span><span class=\"p\">,</span> <span class=\"n\">rr_site2</span><span class=\"p\">,</span> <span class=\"n\">cc_chr_band</span><span class=\"p\">,</span> <span class=\"n\">cc_t_t</span><span class=\"p\">,</span> <span class=\"n\">cc_c_s</span><span class=\"p\">,</span> <span class=\"n\">cc_m_t</span><span class=\"p\">,</span> <span class=\"n\">cc_t_p</span><span class=\"p\">,</span> <span class=\"n\">dgv_site1</span><span class=\"p\">,</span> <span class=\"n\">dgv_site2</span><span class=\"p\">]</span>\n\n        <span class=\"n\">count</span> <span class=\"o\">=</span> <span class=\"n\">count</span> <span class=\"o\">+</span> <span class=\"mi\">1</span>\n\n    <span class=\"c1\"># Write Output</span>\n    <span class=\"n\">outFile</span> <span class=\"o\">=</span> <span class=\"n\">outDir</span> <span class=\"o\">+</span> <span class=\"s2\">&quot;/&quot;</span> <span class=\"o\">+</span> <span class=\"n\">outputPrefix</span> <span class=\"o\">+</span> <span class=\"s2\">&quot;_merged.txt&quot;</span>\n    <span class=\"n\">outDF</span><span class=\"o\">.</span><span class=\"n\">to_csv</span><span class=\"p\">(</span><span class=\"n\">outFile</span><span class=\"p\">,</span> <span class=\"n\">sep</span><span class=\"o\">=</span><span class=\"s1\">&#39;</span><span class=\"se\">\\t</span><span class=\"s1\">&#39;</span><span class=\"p\">,</span> <span class=\"n\">index</span><span class=\"o\">=</span><span class=\"kc\">False</span><span class=\"p\">)</span>\n    <span class=\"k\">if</span><span class=\"p\">(</span><span class=\"n\">verbose</span><span class=\"p\">):</span>\n        <span class=\"n\">logger</span><span class=\"o\">.</span><span class=\"n\">info</span><span class=\"p\">(</span><span class=\"s2\">&quot;iCallSV::MergeFinalFile: Finished merging, Final data written in </span><span class=\"si\">%s</span><span class=\"s2\">&quot;</span><span class=\"p\">,</span> <span class=\"n\">outFile</span><span class=\"p\">)</span>\n    <span class=\"k\">return</span><span class=\"p\">(</span><span class=\"n\">outFile</span><span class=\"p\">)</span></div>\n</pre></div>", "title": "iCallSV.mergeFinalFiles", "customsidebar": null, "current_page_name": "_modules/iCallSV/mergeFinalFiles", "sidebars": null, "parents": [{"link": "../../", "title": "Module code"}], "alabaster_version": "0.7.9"}