Skip to content
Snippets Groups Projects
Commit 5bc467c7 authored by Brandi Cantarel's avatar Brandi Cantarel
Browse files

update determine tid

parent f65dccb0
No related merge requests found
......@@ -66,14 +66,19 @@ then
fi
mkdir -p temp
if [[ -z $tid ]]
if [[ -z $tid ]] && [[ -f ${sbam} ]]
then
tid=`samtools view -H ${sbam} |grep '^@RG' |perl -pe 's/\t/\n/g' |grep ID |cut -f 2 -d ':'`
fi
bams=''
for i in *.bam; do
bams="$bams $i"
bams="$bams $i"
sid=`samtools view -H ${i} |grep '^@RG' |perl -pe 's/\t/\n/g' |grep ID |cut -f 2 -d ':'`
if [[ $sid =~ "_T_" ]]
then
tid=$sid
fi
done
#RUN DELLY
......@@ -92,6 +97,7 @@ then
then
zcat ${pair_id}.delly.vcf.gz | $SNPEFF_HOME/scripts/vcfEffOnePerLine.pl |java -jar $SNPEFF_HOME/SnpSift.jar extractFields - CHROM POS CHR2 END ANN[*].EFFECT ANN[*].GENE ANN[*].BIOTYPE FILTER FORMAT GEN[*] |grep -E 'gene_fusion|feature_fusion' | sort -u > ${pair_id}.dgf.txt
mv ${pair_id}.delly.vcf.gz ${pair_id}.delly.ori.vcf.gz
echo "perl $baseDir/filter_delly.pl -t $tid -p $pair_id -i ${pair_id}.delly.ori.vcf.gz"
perl $baseDir/filter_delly.pl -t $tid -p $pair_id -i ${pair_id}.delly.ori.vcf.gz
bgzip -f ${pair_id}.delly.vcf
zgrep '#CHROM' ${pair_id}.delly.vcf.gz > ${pair_id}.delly.genefusion.txt
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment