changeset 74:00f63511d177 draft

Uploaded
author stef
date Fri, 27 Feb 2015 09:45:42 -0500
parents 78f10251a484
children 3515b026d78b
files falco-filter-report.sh falco-filter-report.xml falco/lib/perl/filter.pl
diffstat 3 files changed, 25 insertions(+), 16 deletions(-) [+]
line wrap: on
line diff
--- a/falco-filter-report.sh	Fri Feb 27 09:33:15 2015 -0500
+++ b/falco-filter-report.sh	Fri Feb 27 09:45:42 2015 -0500
@@ -20,12 +20,19 @@
 ## ----------
 ## set params
 ## ----------
-# if [[ $filter_file != 'None' && $filter_file != '' ]] # Galaxy default is "None" for some reason
-# then 
-# 	FILTER_PARAM=" --filter "$filter_file
-# else
-# 	FILTER_PARAM=""
-# fi
+if [[ $canonicals_file != 'None' && $canonicals_file != '' ]] # Galaxy default is "None" for some reason
+then 
+	CANONICALS_PARAM=" --canonicals "$canonicals_file
+else
+	CANONICALS_PARAM=""
+fi
+
+if [[ $vcf2_file != 'None' && $vcf2_file != '' ]] # Galaxy default is "None" for some reason
+then 
+	VCF2_PARAM=" --vcfOther "$vcf2_file
+else
+	VCF2_PARAM=""
+fi
 
 # if [[ $manifest_file != 'None' && $manifest_file != 'None' ]] # Galaxy default is "None" for some reason
 # then 
@@ -66,7 +73,7 @@
 ## running analysis
 ## ----------
 echo "[INFO] Starting FALCO reporting"
-CMD_STRING="$TOOLDIR/falco/bin/falco-filter-report --vcf $vcf_file --output $vcf_base --qc_ann_qual_txt $qc_ann_qual_file --qc2_ann_txt $qc2_ann_txt_file --qc_targets_txt $qc_targets_txt_file"
+CMD_STRING="$TOOLDIR/falco/bin/falco-filter-report --vcf $vcf_file --output $vcf_base --qc_ann_qual_txt $qc_ann_qual_file --qc2_ann_txt $qc2_ann_txt_file --qc_targets_txt $qc_targets_txt_file $VCF2_PARAM $CANONICALS_PARAM"
 echo "[INFO] "$CMD_STRING
 perl $CMD_STRING
 echo "[INFO] done with FALCO reporting"
--- a/falco-filter-report.xml	Fri Feb 27 09:33:15 2015 -0500
+++ b/falco-filter-report.xml	Fri Feb 27 09:45:42 2015 -0500
@@ -50,6 +50,7 @@
     <param format="tsv" name="qc_ann_qual" optional="false" type="data" label="qc_ann_qual file" help=""/>
     <param format="tsv" name="qc2_ann_txt" optional="false" type="data" label="qc2_ann_txt file" help=""/>
     <param format="tsv" name="qc_targets_txt" optional="false" type="data" label="qc_targets_txt file" help=""/>
+    <param format="tsv" name="canonicals" optional="true" type="data" label="canonicals file" help=""/>
 
     <!-- ==================== -->
     <!-- Option to use your own bin annotations -->
@@ -65,6 +66,7 @@
 
       vcf_file=$vcf
       vcf_file2=$vcf2
+      canonicals_file=$canonicals
       
       qc_ann_qual_file=$qc_ann_qual
       qc2_ann_txt_file=$qc2_ann_txt
--- a/falco/lib/perl/filter.pl	Fri Feb 27 09:33:15 2015 -0500
+++ b/falco/lib/perl/filter.pl	Fri Feb 27 09:45:42 2015 -0500
@@ -81,15 +81,15 @@
 	$trans =~ s/\..*$//;
 	
 	## impossible to switch off these two transcript filters
-	## so commented out for now
-	# if (not exists($nm{$trans})) {
-	# 	print STDERR "Unknown transcript: $row[$col{Gene_Name}] $trans\n";
-	# 	next;
-	# }
-	# elsif ($nm{$trans} != 0) {
-	# 	print STDERR "Non cannonical: $row[$col{Gene_Name}] $trans\n";
-	# 	next;
-	# }
+	## so comment these out if no other way provided
+	if (not exists($nm{$trans})) {
+		print STDERR "Unknown transcript: $row[$col{Gene_Name}] $trans\n";
+		next;
+	}
+	elsif ($nm{$trans} != 0) {
+		print STDERR "Non cannonical: $row[$col{Gene_Name}] $trans\n";
+		next;
+	}
 
 	# Annotate clinincal variants and cosmic mutations