diff --git a/codes/target_therapy_cnv.pl b/codes/target_therapy_cnv.pl index f14c075..2bafe53 100755 --- a/codes/target_therapy_cnv.pl +++ b/codes/target_therapy_cnv.pl @@ -108,6 +108,10 @@ while () { if ($cn >= 4 and exists $therapy{lc $cnv_detected}{lc 'Amplification'}) { foreach my $entry (@{$therapy{lc $cnv_detected}{lc 'Amplification'}}) { my @line = split("\t", $entry); + if (!defined($line[16])) { + $line[16] = ''; + } + my $dises; if (!(exists $dis{lc $line[2]})) { $dises = 'unknow'; @@ -116,16 +120,16 @@ while () { $dises = $dis{lc $line[2]}; } if (($line[14] eq 'A') and (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$cn\tOncogenic\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症\t" . &drug($line[3]) . "\t" . $dises; + push @pos, "$_\t$cn\tOncogenic\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症\t" . &drug($line[3]) . "\t" . $dises . "\t" . $line[16]; $bool = 1; } elsif (($line[14] eq 'A') and (grep {lc $line[2] ne lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$cn\tOncogenic\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症\t" . &drug($line[3]) . "\t" . $dises; + push @pos, "$_\t$cn\tOncogenic\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症\t" . &drug($line[3]) . "\t" . $dises . "\t" . $line[16]; $bool = 1; } elsif (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}}) { - push @pos, "$_\t$cn\tOncogenic\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dises; + push @pos, "$_\t$cn\tOncogenic\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dises . "\t" . $line[16]; $bool = 1; } } @@ -141,15 +145,15 @@ while () { $dises = $dis{lc $line[2]}; } if (($line[14] eq 'A') and (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$cn\tOncogenic\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症\t" . &drug($line[3]) . "\t" . $dises; + push @pos, "$_\t$cn\tOncogenic\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症\t" . &drug($line[3]) . "\t" . $dises . "\t" . $line[16]; $bool = 1; } elsif (($line[14] eq 'A') and (grep {lc $line[2] ne lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$cn\tOncogenic\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症\t" . &drug($line[3]) . "\t" . $dises; + push @pos, "$_\t$cn\tOncogenic\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症\t" . &drug($line[3]) . "\t" . $dises . "\t" . $line[16]; $bool = 1; } elsif (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}}) { - push @pos, "$_\t$cn\tOncogenic\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dises; + push @pos, "$_\t$cn\tOncogenic\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dises . "\t" . $line[16]; $bool = 1; } } diff --git a/codes/target_therapy_fusion.pl b/codes/target_therapy_fusion.pl index 79cd08f..544fb76 100755 --- a/codes/target_therapy_fusion.pl +++ b/codes/target_therapy_fusion.pl @@ -128,16 +128,19 @@ while () { if (exists $therapy{lc $gene}{lc "$record{'FUSION'} Fusion"}) { foreach my $entry (@{$therapy{lc $gene}{lc "$record{'FUSION'}Fusion"}}) { my @line = split("\t", $entry); + if (!defined($line[16])) { + $line[16] = ''; + } if (($line[14] eq 'A') and (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$sig\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$sig\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (($line[14] eq 'A') and (grep {lc $line[2] ne lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$sig\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$sig\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}}) { - push @pos, "$_\t$sig\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$sig\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } } @@ -147,15 +150,15 @@ while () { foreach my $entry (@{$therapy{lc $gene}{lc "Fusion"}}) { my @line = split("\t", $entry); if (($line[14] eq 'A') and (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$sig\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$sig\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (($line[14] eq 'A') and (grep {lc $line[2] ne lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$sig\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$sig\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}}) { - push @pos, "$_\t$sig\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$sig\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } } diff --git a/codes/target_therapy_longindel.pl b/codes/target_therapy_longindel.pl index 26ed406..feeb7a6 100755 --- a/codes/target_therapy_longindel.pl +++ b/codes/target_therapy_longindel.pl @@ -106,14 +106,18 @@ while () { if (exists $therapy{lc 'BCL2L11'}{lc 'DELETION POLYMORPHISM'}) { foreach my $entry (@{$therapy{lc 'BCL2L11'}{lc 'DELETION POLYMORPHISM'}}) { my @line = split("\t", $entry); + if (!defined($line[16])) { + $line[16] = ''; + } + if (($line[14] eq 'A') and (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; } elsif (($line[14] eq 'A') and (grep {lc $line[2] ne lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; } elsif (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}}) { - push @pos, "$_\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; } } diff --git a/codes/target_therapy_snpindel.pl b/codes/target_therapy_snpindel.pl index 8373802..0ba2040 100755 --- a/codes/target_therapy_snpindel.pl +++ b/codes/target_therapy_snpindel.pl @@ -81,7 +81,7 @@ open VUS, ">$output.vus.txt"; my $h2 = ; chomp $h2; -my $h = $h2 . "\tfun_change\t" . join("\t", (split("\t", $h1))[0 .. 9, 14]) . "\tLabel\tDrugCn\tIndication"; +my $h = $h2 . "\tfun_change\t" . join("\t", (split("\t", $h1))[0 .. 9, 14]) . "\tLabel\tDrugCn\tIndication\treport_need_note"; print POS "$h\n"; print NEG $h2 . "\tfun_change\n"; print VUS $h2 . "\tfun_change\n"; @@ -116,7 +116,6 @@ while () { } elsif ($record{'ExonicFunc_refGene'} =~ /skipping/) { $protein = 'Exon 14 Skipping Mutation'; - print "$protein\n"; $mut_type = ''; } elsif ($record{'Func_refGene'} =~ /splicing/) { @@ -158,16 +157,20 @@ while () { if (exists $therapy{lc $gene}{lc $protein}) { foreach my $entry (@{$therapy{lc $gene}{lc $protein}}) { my @line = split("\t", $entry); + if (!defined($line[16])) { + $line[16] = ''; + } + if (($line[14] eq 'A') and (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (($line[14] eq 'A') and (grep {lc $line[2] ne lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}}) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } } @@ -176,16 +179,19 @@ while () { if (exists $therapy{lc $gene}{'mutation'}) { foreach my $entry (@{$therapy{lc $gene}{'mutation'}}) { my @line = split("\t", $entry); + if (!defined($line[16])) { + $line[16] = ''; + } if (($line[14] eq 'A') and (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (($line[14] eq 'A') and (grep {lc $line[2] ne lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}}) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } } @@ -194,16 +200,19 @@ while () { if ($protein =~ /^(\w\d+)\w$/ and exists $therapy{lc $gene}{lc $1}) { foreach my $entry (@{$therapy{lc $gene}{lc $1}}) { my @line = split("\t", $entry); + if (!defined($line[16])) { + $line[16] = ''; + } if (($line[14] eq 'A') and (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (($line[14] eq 'A') and (grep {lc $line[2] ne lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}}) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } } @@ -212,16 +221,19 @@ while () { if ($protein =~ /^(\w\d+)\w$/ and exists $therapy{lc $gene}{lc $1 . "X"}) { foreach my $entry (@{$therapy{lc $gene}{lc $1 . "X"}}) { my @line = split("\t", $entry); + if (!defined($line[16])) { + $line[16] = ''; + } if (($line[14] eq 'A') and (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (($line[14] eq 'A') and (grep {lc $line[2] ne lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}}) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } } @@ -230,16 +242,19 @@ while () { if (exists $therapy{lc $gene}{lc $mut_type}) { foreach my $entry (@{$therapy{lc $gene}{lc $mut_type}}) { my @line = split("\t", $entry); + if (!defined($line[16])) { + $line[16] = ''; + } if (($line[14] eq 'A') and (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (($line[14] eq 'A') and (grep {lc $line[2] ne lc $_} @{$dis2{$cancer_type}})) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t非适应症" . "\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } elsif (grep {lc $line[2] eq lc $_} @{$dis2{$cancer_type}}) { - push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]}; + push @pos, "$_\t$mut{lc $gene}{lc $protein}\t" . join("\t", @line[0 .. 9, 14]) . "\t\.\t" . &drug($line[3]) . "\t" . $dis{lc $line[2]} . "\t" . $line[16]; $bool = 1; } } diff --git a/wdl/msi.wdl b/wdl/msi.wdl index b804b83..95946ad 100755 --- a/wdl/msi.wdl +++ b/wdl/msi.wdl @@ -27,7 +27,7 @@ task run_msi { echo "msi 624 探针 " msisensor2 msi \ -M /dataseq/jmdna/software/msisensor2/models_hg19_GRCh37 \ - -t ${tumor_rmdup_bam} -e $PUBLIC/msi//624_650_intersect_depth50_177.bed -b 10 \ + -t ${tumor_rmdup_bam} -e $PUBLIC/msi/624_650_intersect_depth50_177.bed -b 10 \ -o ${output_dir}/msi/${name}.msi.txt elif [ "${probe}" == "160" ]; then