Previous changeset 0:1c37a8003755 (2015-09-28) Next changeset 2:70e3c4c34a7c (2015-09-29) |
Commit message:
Deleted selected files |
removed:
trinityrnaseq_protocol/EdgeR_differentialExpression.xml trinityrnaseq_protocol/EdgeR_differentialExpression_wrapper.py trinityrnaseq_protocol/RSEM_estimates_to_matrix.xml trinityrnaseq_protocol/abundance_estimation_to_matrix.xml trinityrnaseq_protocol/abundance_estimation_to_matrix_wrapper.py trinityrnaseq_protocol/align_and_estimate_abundance.xml trinityrnaseq_protocol/alignreads.xml trinityrnaseq_protocol/analyze_diff_exp.xml trinityrnaseq_protocol/analyze_diff_exp_wrapper.py trinityrnaseq_protocol/cat.xml trinityrnaseq_protocol/diffExpress_edgeR.xml trinityrnaseq_protocol/trinityToolWrapper.py |
b |
diff -r 1c37a8003755 -r 4eaf6b15b1b2 trinityrnaseq_protocol/EdgeR_differentialExpression.xml --- a/trinityrnaseq_protocol/EdgeR_differentialExpression.xml Mon Sep 28 22:44:29 2015 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
b |
@@ -1,38 +0,0 @@ -<tool id="EdgeR_differentialExpression" name="EdgeR_differentialExpression" version="0.0.1"> - - <description>Identify Differentially Expressed Transcripts Using EdgeR</description> - <requirements> - <requirement type="package">trinity</requirement> - </requirements> - <command interpreter="python"> - - EdgeR_differentialExpression_wrapper.py - $counts_matrix - $dispersion - - </command> - <inputs> - - <param type="data" format="txt" name="counts_matrix" label="Matrix of RNA-Seq fragment counts for transcripts per condition" /> - <param type="data" format="fasta" name="transcripts_fasta_file" label="Transcripts fasta file corresponding to matrix" /> - <param type="float" name="dispersion" value="0.1" min="0" label="dispersion value" help="Dispersion value to be used in the negative binomial" /> - - </inputs> - <outputs> - - <data format="tar.gz" name="EdgeR_Archive" label="${tool.name} on ${on_string}: EdgeR_Results.tar.gz" from_work_dir="edgeR_results.tar.gz" /> - - </outputs> - <tests> - - <test> - <param name="myname" value="This is just a simple test" /> - - </test> - - - </tests> - <help> - help info here. - </help> -</tool> |
b |
diff -r 1c37a8003755 -r 4eaf6b15b1b2 trinityrnaseq_protocol/EdgeR_differentialExpression_wrapper.py --- a/trinityrnaseq_protocol/EdgeR_differentialExpression_wrapper.py Mon Sep 28 22:44:29 2015 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
[ |
@@ -1,40 +0,0 @@ -import sys, os, subprocess - -TRINITY_BASE_DIR = "" -if os.environ.has_key('TRINITY_HOME'): - TRINITY_BASE_DIR = os.environ['TRINITY_HOME']; -else: - sys.stderr.write("You must set the environmental variable TRINITY_BASE_DIR to the base installation directory of Trinity before running this"); - sys.exit(1) - -usage= "usage: " + " $counts_matrix" + " $dispersion" - -if len(sys.argv)<2: - print "Require atleast two parameters" -else: - print "All good- command going ahead" -print " " - -def run_command(cmd): - print "The command used: " + cmd - pipe=subprocess.Popen(cmd, shell=True, stderr=subprocess.PIPE) - pipe.wait() - ret= pipe.returncode - if ret: - print "command died: " + str(ret) - print pipe.stderr.readlines() - sys.exit(1) - else: - return -print " " - -countmatrix= "counts_matrix" - -cmd= "cp " + sys.argv[1] + " " + countmatrix -run_command(cmd) - -cmd= TRINITY_BASE_DIR + "/Analysis/DifferentialExpression/run_DE_analysis.pl "+ " --matrix "+ countmatrix + " --method edgeR " + " --output edgeR_results "+ " --dispersion " + sys.argv[2] + " --tar_gz_outdir" - -run_command(cmd) - -sys.exit(0) |
b |
diff -r 1c37a8003755 -r 4eaf6b15b1b2 trinityrnaseq_protocol/RSEM_estimates_to_matrix.xml --- a/trinityrnaseq_protocol/RSEM_estimates_to_matrix.xml Mon Sep 28 22:44:29 2015 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
b |
@@ -1,51 +0,0 @@ -<tool id="RSEM_estimates_to_matrix" name="RSEM_estimates_to_matrix" version="0.0.1"> - - <description>Join RSEM estimates from multiple samples into a single matrix</description> - <requirements> - <requirement type="package">trinity</requirement> - </requirements> - <command interpreter="python"> - - trinityToolWrapper.py util/RSEM_util/merge_RSEM_counts_and_labels_single_table.pl - - --labels - #for $entry in $RSEM_samples: - ${entry.column_label} - #end for - - --RSEM_counts - #for $entry in $RSEM_samples: - ${entry.file} - #end for - - > RSEM.counts.matrix - - </command> - <inputs> - - <repeat name="RSEM_samples" title="RSEM abundance estimates for samples"> - <param name="file" label="Add file" type="data" format="text"/> - <param name="column_label" label="column label" type="text" /> - </repeat> - - </inputs> - <outputs> - <data format="text" name="counts_matrix" label="${tool.name} on ${on_string}: Counts Matrix" from_work_dir="RSEM.counts.matrix"/> - </outputs> - <tests> - - - <test> - <param name="target" value="trinity/Trinity.fasta" /> - <param name="aligner" value="bowtie" /> - <param name="paired_or_single" value="single" /> - <param name="library_type" value="None" /> - <param name="input" value="trinity/reads.left.fq" /> - </test> - - - </tests> - <help> - .. _Trinity: http://trinityrnaseq.sourceforge.net - </help> -</tool> |
b |
diff -r 1c37a8003755 -r 4eaf6b15b1b2 trinityrnaseq_protocol/abundance_estimation_to_matrix.xml --- a/trinityrnaseq_protocol/abundance_estimation_to_matrix.xml Mon Sep 28 22:44:29 2015 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
b |
@@ -1,42 +0,0 @@ -<tool id="abundance_estimation_to_matrix" name="abundance_estimation_to_matrix" version="0.0.1"> - - <description>Join RSEM estimates from multiple samples into a single matrix</description> - <requirements> - <requirement type="package">trinity</requirement> - </requirements> - <command interpreter="python"> - - abundance_estimation_to_matrix_wrapper.py - #for $q in $RSEM_samples - ${q.file} "${q.column_label}" - #end for - - </command> - <inputs> - - <repeat name="RSEM_samples" title="RSEM abundance estimates for samples"> - <param name="file" label="Add file" type="data" format="text"/> - <param name="column_label" label="column label" type="text" /> - </repeat> - - </inputs> - <outputs> - <data format="text" name="counts_matrix" label="${tool.name} on ${on_string}: Counts Matrix" from_work_dir="matrix.counts.matrix"/> - </outputs> - <tests> - - - <test> - <param name="target" value="trinity/Trinity.fasta" /> - <param name="aligner" value="bowtie" /> - <param name="paired_or_single" value="single" /> - <param name="library_type" value="None" /> - <param name="input" value="trinity/reads.left.fq" /> - </test> - - - </tests> - <help> - .. _Trinity: http://trinityrnaseq.sourceforge.net - </help> -</tool> |
b |
diff -r 1c37a8003755 -r 4eaf6b15b1b2 trinityrnaseq_protocol/abundance_estimation_to_matrix_wrapper.py --- a/trinityrnaseq_protocol/abundance_estimation_to_matrix_wrapper.py Mon Sep 28 22:44:29 2015 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
[ |
@@ -1,40 +0,0 @@ -#!/usr/bin/env python - -import sys, os, string, subprocess - -#aliasing the filenames using the labels - - -def run_command(command): - print "Running command: " + command - - err_capture_file = open("my.stderr", 'w') # writing stderr to a file - cmd_run = subprocess.Popen(args=command, shell=True, stderr=err_capture_file, stdout=sys.stdout) - err = cmd_run.wait() # get exit code from command execution - err_capture_file.close() - - if err: - # report the error messages we captured, and exit non-zero - sys.stderr.write("Error, cmd: " + command + " died with ret: " + `err`) - for line in open(err_capture_file): - sys.stderr.write(line) - sys.exit(err) - return - -label_list = [] # symlink files to the labels -for i in range(1, len(sys.argv), 2): - filename=sys.argv[i] - label= sys.argv[i+1] - cmd= "ln -sf " + filename + " " + label - label_list.append(label) - run_command(cmd) - - -# run the abundance estimation script - -cmd = os.path.dirname(sys.argv[0]) + "/trinityToolWrapper.py " + " util/abundance_estimates_to_matrix.pl --est_method RSEM --cross_sample_fpkm_norm TMM " + " ".join(label_list) - -run_command(cmd) - -sys.exit(0) - |
b |
diff -r 1c37a8003755 -r 4eaf6b15b1b2 trinityrnaseq_protocol/align_and_estimate_abundance.xml --- a/trinityrnaseq_protocol/align_and_estimate_abundance.xml Mon Sep 28 22:44:29 2015 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
b |
@@ -1,90 +0,0 @@ -<tool id="RSEM_abundance_estimation" name="RSEM_abundance_estimation" version="0.0.1"> - - <description>run RSEM to estimate transcript abundances</description> - <requirements> - <requirement type="package">trinity</requirement> - </requirements> - <command interpreter="python"> - - trinityToolWrapper.py util/align_and_estimate_abundance.pl --transcripts $transcripts --est_method RSEM --aln_method bowtie --trinity_mode --prep_reference - - ## Inputs. - #if str($inputs.paired_or_single) == "paired": - --left $inputs.left_input --right $inputs.right_input - #if $inputs.left_input.ext == 'fa': - --seqType fa - #else: - --seqType fq - #end if - #if str($inputs.library_type) != "None": - --SS_lib_type $inputs.library_type - #end if - - #else: - --single $inputs.input - #if str($inputs.input.ext) == 'fa': - --seqType fa - #else: - --seqType fq - #end if - #if str($inputs.library_type) != "None": - --SS_lib_type $inputs.library_type - #end if - #end if - - - </command> - <inputs> - <param format="fasta" name="transcripts" type="data" label="transcripts_fasta" help="Fasta sequences for which reads are aligned." /> - - <conditional name="inputs"> - <param name="paired_or_single" type="select" label="Paired or Single-end data?"> - <option value="paired">Paired</option> - <option value="single">Single</option> - </param> - <when value="paired"> - <param format="fasta,fastq" name="left_input" type="data" label="Left/Forward strand reads" help=""/> - <param format="fasta,fastq" name="right_input" type="data" label="Right/Reverse strand reads" help=""/> - <param name="library_type" type="select" label="Strand-specific Library Type"> - <option value="None">None</option> - <option value="FR">FR</option> - <option value="RF">RF</option> - </param> - - </when> - <when value="single"> - <param format="fasta,fastq" name="input" type="data" label="Single-end reads" help=""/> - <param name="library_type" type="select" label="Strand-specific Library Type"> - <option value="None">None</option> - <option value="F">F</option> - <option value="R">R</option> - </param> - - </when> - </conditional> - - - </inputs> - <outputs> - <data format="text" name="transcript_counts" label="${tool.name} on ${on_string}: Isoform Counts" from_work_dir="RSEM.isoforms.results"/> - <data format="text" name="gene_counts" label="${tool.name} on ${on_string}: Gene counts" from_work_dir="RSEM.genes.results"/> - - - </outputs> - <tests> - - - <test> - <param name="target" value="trinity/Trinity.fasta" /> - <param name="aligner" value="bowtie" /> - <param name="paired_or_single" value="single" /> - <param name="library_type" value="None" /> - <param name="input" value="trinity/reads.left.fq" /> - </test> - - - </tests> - <help> - .. _Trinity: http://trinityrnaseq.sourceforge.net - </help> -</tool> |
b |
diff -r 1c37a8003755 -r 4eaf6b15b1b2 trinityrnaseq_protocol/alignreads.xml --- a/trinityrnaseq_protocol/alignreads.xml Mon Sep 28 22:44:29 2015 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
b |
@@ -1,138 +0,0 @@ -<tool id="alignreads" name="alignReads" version="0.0.1"> - - <description>alignReads: short read alignment tool wrapper</description> - <requirements> - <requirement type="package">trinity</requirement> - </requirements> - <command interpreter="python"> - - trinityToolWrapper.py util/alignReads.pl --target $target -o alignment --aligner $aligner_selection.aligner - - - ## Inputs. - #if str($inputs.paired_or_single) == "paired": - --left $inputs.left_input --right $inputs.right_input - #if $inputs.left_input.ext == 'fa': - --seqType fa - #else: - --seqType fq - #end if - #if str($inputs.library_type) != "None": - --SS_lib_type $inputs.library_type - #end if - --max_dist_between_pairs $inputs.max_dist_between_pairs - #else: - --single $inputs.input - #if str($inputs.input.ext) == 'fa': - --seqType fa - #else: - --seqType fq - #end if - #if str($inputs.library_type) != "None": - --SS_lib_type $inputs.library_type - #end if - #end if - - ## Additional parameters. - ##if str($inputs.use_additional) == "yes": - ## -- $inputs.additional_params - ##end if - - - ## direct to output - > outCapture.txt - - - </command> - <inputs> - <param format="fasta" name="target" type="data" label="target" help="Fasta sequences targeted for short-read alignment" /> - - <conditional name="inputs"> - <param name="paired_or_single" type="select" label="Paired or Single-end data?"> - <option value="paired">Paired</option> - <option value="single">Single</option> - </param> - <when value="paired"> - <param format="fasta,fastq" name="left_input" type="data" label="Left/Forward strand reads" help=""/> - <param format="fasta,fastq" name="right_input" type="data" label="Right/Reverse strand reads" help=""/> - <param name="library_type" type="select" label="Strand-specific Library Type"> - <option value="None">None</option> - <option value="FR">FR</option> - <option value="RF">RF</option> - </param> - <param name="max_dist_between_pairs" type="integer" value="2000" min="1" label="max_dist_between_pairs" help="Maximum length expected between fragment pairs as aligned to the target, including introns where relevant."/> - - - </when> - <when value="single"> - <param format="fasta,fastq" name="input" type="data" label="Single-end reads" help=""/> - <param name="library_type" type="select" label="Strand-specific Library Type"> - <option value="None">None</option> - <option value="F">F</option> - <option value="R">R</option> - </param> - </when> - </conditional> - - <conditional name="aligner_selection"> - <param name="aligner" type="select" label="Select alignment tool to run"> - <option value="bowtie">bowtie</option> - <option value="bwa">bwa</option> - <option value="blat">blat</option> - </param> - <when value="blat"> - <param name="max_intron_length" type="integer" value="10000" min = "1" label="maximum intron length" help="" /> - <param name="min_percent_identity" type="integer" value="95" min="1" label="minimum percent identity" help="" /> - </when> - <when value="bwa"> - </when> - <when value="bowtie"> - </when> - </conditional> - - - <!-- - <conditional name="use_additional_params"> - <param name="use_additional" type="select" label="Use Additional Params?"> - <option value="no">No</option> - <option value="yes">Yes</option> - </param> - <when value="no"> - </when> - <when value="yes"> - <param name="additional_params" type="text" value="" label="Additional command-line parameters to aligner" help="" /> - </when> - </conditional> - - --> - - </inputs> - <outputs> - <data format="bam" name="coordSortedBam" label="${tool.name} on ${on_string}: COORD-sorted read alignments" from_work_dir="alignment/alignment.coordSorted.bam"/> - <data format="bam" name="nameSortedBam" label="${tool.name} on ${on_string}: NAME-sorted read alignments" from_work_dir="alignment/alignment.nameSorted.bam"/> - - <!-- notes: need to retain: - -the sample name for the alignment - -coordinate-sorted vs. name-sorted bam file - -paired vs. unpaired vs. strictly proper pairs (for RSEM) - -strand-specific or not - --> - - </outputs> - <tests> - - - <test> - <param name="target" value="trinity/Trinity.fasta" /> - <param name="aligner" value="bowtie" /> - <param name="paired_or_single" value="single" /> - <param name="library_type" value="None" /> - <param name="input" value="trinity/reads.left.fq" /> - </test> - - - </tests> - <help> - .. _Trinity: http://trinityrnaseq.sourceforge.net - </help> -</tool> |
b |
diff -r 1c37a8003755 -r 4eaf6b15b1b2 trinityrnaseq_protocol/analyze_diff_exp.xml --- a/trinityrnaseq_protocol/analyze_diff_exp.xml Mon Sep 28 22:44:29 2015 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
b |
@@ -1,41 +0,0 @@ -<tool id="Analyze_Diff_Exp" name="Analyze_Differential_Expression" version="0.0.1"> - - <description>Analyze differential expression</description> - <requirements> - <requirement type="package">trinity</requirement> - </requirements> - <command interpreter="python"> - - analyze_diff_exp_wrapper.py $EdgeRTarGz $TMM_Matrix_FPKM $Pvalue $Cvalue - - </command> - <inputs> - <param name="EdgeRTarGz" label="EdgeR tar gz file" type="data" format="file"/> - <param name="TMM_Matrix_FPKM" label="TMM Normalized FPKM matrix" type="data" format="file" /> - <param name="Pvalue" label="P-value" value="0.05" type="float" /> - <param name="Cvalue" label="C-value" value="0" type="float" /> - - </inputs> - <outputs> - <data format="data" name="diffExpr_matrix" label="${tool.name} on ${on_string}: Matrix" from_work_dir="diffExpr.matrix"/> - <data format="data" name="diffExpr_correlation_matrix" label="${tool.name} on ${on_string}: Sample_Correlation_Matrix" from_work_dir="diffExpr.matrix.log2.sample_cor.dat"/> - <data format="data" name="diffExpr_correlation_matrix_pdf" label="${tool.name} on ${on_string}: Sample_Correlation_Matrix_PDF" from_work_dir="diffExpr.matrix.log2.sample_cor_matrix.pdf"/> - <data format="data" name="Heatmap" label="${tool.name} on ${on_string}: Heatmap" from_work_dir="diffExpr.matrix.log2.centered.genes_vs_samples_heatmap.pdf"/> - </outputs> - <tests> - - - <test> - <param name="target" value="trinity/Trinity.fasta" /> - <param name="aligner" value="bowtie" /> - <param name="paired_or_single" value="single" /> - <param name="library_type" value="None" /> - <param name="input" value="trinity/reads.left.fq" /> - </test> - - - </tests> - <help> - .. _Trinity: http://trinityrnaseq.sourceforge.net - </help> -</tool> |
b |
diff -r 1c37a8003755 -r 4eaf6b15b1b2 trinityrnaseq_protocol/analyze_diff_exp_wrapper.py --- a/trinityrnaseq_protocol/analyze_diff_exp_wrapper.py Mon Sep 28 22:44:29 2015 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
[ |
@@ -1,63 +0,0 @@ -import sys, os, subprocess - -TRINITY_BASE_DIR = "" -if os.environ.has_key('TRINITY_HOME'): - TRINITY_BASE_DIR = os.environ['TRINITY_HOME']; -else: - sys.stderr.write("You must set the environmental variable TRINITY_BASE_DIR to the base installation directory of Trinity before running this"); - sys.exit() - -usage= "usage: " + sys.argv[0] + " " + "edgeR.tar.gz " + "TMM_normalized_FPKM_matrix " + "P-value " + "C-value" -print sys.argv -print usage -print " " - -if len(sys.argv)<5: - print "Require atleast two parameters" -else: - print "All good- command going ahead" -print " " - -Normalized_Matrix=sys.argv[2] -Pvalue=sys.argv[3] -Cvalue=sys.argv[4] - -def run_command(cmd): - print "The command used: " + cmd - pipe= subprocess.Popen(cmd, shell=True, stderr=subprocess.PIPE) - pipe.wait() - ret= pipe.returncode - if ret: - print "command died: " + str(ret) - print pipe.stderr.readlines() - sys.exit(1) - else: - return -print " " - -Final_tar_gz= "edgeR.tar.gz" -run_command("cp "+ sys.argv[1] + " " + "Final_tar_gz") -run_command("tar -xvf " + "Final_tar_gz") -run_command("mv " + "edgeR_results" + "/* ." ) - -# run the analyze command -cmd= TRINITY_BASE_DIR + "/Analysis/DifferentialExpression/analyze_diff_expr.pl "+ "--matrix " + Normalized_Matrix + " -P " + Pvalue + " -C " + Cvalue -run_command(cmd) - -origMatrixName= "diffExpr.P" + Pvalue + "_" + "C" + Cvalue + ".matrix" -# diffExpr.P0.001_C2.0.matrix -run_command("mv " + origMatrixName + " diffExpr.matrix") - -SampleCorName= "diffExpr.P" + Pvalue + "_" + "C" + Cvalue + ".matrix.log2.sample_cor.dat" -# diffExpr.P0.001_C2.0.matrix.log2.sample_cor.dat -run_command("mv " + SampleCorName + " diffExpr.matrix.log2.sample_cor.dat") - -CorMatrix= "diffExpr.P" + Pvalue + "_" + "C" + Cvalue + ".matrix.log2.sample_cor_matrix.pdf" -# diffExpr.P0.001_C2.0.matrix.log2.sample_cor_matrix.pdf -run_command("mv " + CorMatrix + " diffExpr.matrix.log2.sample_cor_matrix.pdf") - -Heatmap= "diffExpr.P" + Pvalue + "_" + "C" + Cvalue + ".matrix.log2.centered.genes_vs_samples_heatmap.pdf" -#diffExpr.P0.001_C2.0.matrix.log2.centered.genes_vs_samples_heatmap.pdf -run_command("mv " + Heatmap + " diffExpr.matrix.log2.centered.genes_vs_samples_heatmap.pdf") - -sys.exit(0) |
b |
diff -r 1c37a8003755 -r 4eaf6b15b1b2 trinityrnaseq_protocol/cat.xml --- a/trinityrnaseq_protocol/cat.xml Mon Sep 28 22:44:29 2015 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
b |
@@ -1,41 +0,0 @@ -<tool id="catbash" name="Concatenate datasets"> - <description>tail-to-head</description> - <command interpreter="python"> - bash_command_executer.py cat - $input1 - #for $q in $queries - ${q.input2} - #end for - > $out_file1 - </command> - <inputs> - <param name="input1" type="data" label="Concatenate Dataset"/> - <repeat name="queries" title="Dataset"> - <param name="input2" type="data" label="Select" /> - </repeat> - </inputs> - <outputs> - <data name="out_file1" format="input" metadata_source="input1"/> - </outputs> - <tests> - <test> - <param name="input1" value="1.bed"/> - <param name="input2" value="2.bed"/> - <output name="out_file1" file="cat_wrapper_out1.bed"/> - </test> - <!--TODO: if possible, enhance the underlying test code to handle this test - the problem is multiple params with the same name "input2" - <test> - <param name="input1" value="1.bed"/> - <param name="input2" value="2.bed"/> - <param name="input2" value="3.bed"/> - <output name="out_file1" file="cat_wrapper_out2.bed"/> - </test> - --> - </tests> - <help> - - no help - - </help> -</tool> |
b |
diff -r 1c37a8003755 -r 4eaf6b15b1b2 trinityrnaseq_protocol/diffExpress_edgeR.xml --- a/trinityrnaseq_protocol/diffExpress_edgeR.xml Mon Sep 28 22:44:29 2015 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
b |
@@ -1,47 +0,0 @@ -<tool id="diffExpress_edgeR" name="diffExpress_edgeR" version="0.0.1"> - - <description>Identify Differentially Expressed Transcripts Using EdgeR</description> - <requirements> - <requirement type="package">edgeR</requirement> - </requirements> - <command interpreter="python"> - - trinityToolWrapper.py Analysis/DifferentialExpression/run_EdgeR.pl - --matrix $counts_matrix - --transcripts $transcripts_fasta_file - --output edgeR_results - --dispersion $dispersion - - > stdout.txt - - - </command> - <inputs> - - <param type="data" format="txt" name="counts_matrix" label="Matrix of RNA-Seq fragment counts for transcripts per condition" /> - <param type="data" format="fasta" name="transcripts_fasta_file" label="Transcripts fasta file corresponding to matrix" /> - <param type="float" name="dispersion" value="0.1" min="0" label="dispersion value" help="Dispersion value to be used in the negative binomial" /> - - </inputs> - <outputs> - - <data format="txt" name="diff_expressed_edgeR_results" label="${tool.name} on ${on_string}: differentially expressed transcripts per pair of conditions" from_work_dir="edgeR_results/all_diff_expression_results.txt" /> - - <data format="txt" name="matrix_FPKM" label="${tool.name} on ${on_string}: matrix.TMM_normalized.FPKM" from_work_dir="edgeR_results/matrix.TMM_normalized.FPKM" /> - - <data format="txt" name="TMM_info" label="${tool.name} on ${on_string}: TMM library size estimates" from_work_dir="edgeR_results/TMM_info.txt" /> - - </outputs> - <tests> - - <test> - <param name="myname" value="This is just a simple test" /> - - </test> - - - </tests> - <help> - help info here. - </help> -</tool> |
b |
diff -r 1c37a8003755 -r 4eaf6b15b1b2 trinityrnaseq_protocol/trinityToolWrapper.py --- a/trinityrnaseq_protocol/trinityToolWrapper.py Mon Sep 28 22:44:29 2015 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
[ |
@@ -1,82 +0,0 @@ -#!/usr/bin/env python - - -# borrowed from: http://wiki.g2.bx.psu.edu/Future/Job%20Failure%20When%20stderr and modified for use with Trinity tools. - -""" -Wrapper that execute a program and its arguments but reports standard error -messages only if the program exit status was not 0 -Example: ./stderr_wrapper.py myprog arg1 -f arg2 -""" - -import sys, subprocess, os - -assert sys.version_info[:2] >= ( 2, 4 ) - -TRINITY_BASE_DIR = "" -if os.environ.has_key('TRINITY_HOME'): - TRINITY_BASE_DIR = os.environ['TRINITY_HOME']; -else: - sys.stderr.write("You must set the environmental variable TRINITY_BASE_DIR to the base installation directory of Trinity before running this"); - sys.exit() - - - -# get bindir -bindir = sys.argv[0] -bindir = bindir.split("/") -if len(bindir) > 1: - bindir.pop() - bindir = "/".join(bindir) -else: - bindir = "." - - -## add locations of tools to path setting. -TOOL_PATHS_FILE = bindir + "/__add_to_PATH_setting.txt"; -for line in open(TOOL_PATHS_FILE): - line = line.rstrip() - os.environ['PATH'] += ":" + line - - -def stop_err( msg ): - sys.stderr.write( "%s\n" % msg ) - sys.exit() - -def __main__(): - # Get command-line arguments - args = sys.argv - # Remove name of calling program, i.e. ./stderr_wrapper.py - args.pop(0) - # If there are no arguments left, we're done - if len(args) == 0: - return - - # If one needs to silence stdout - #args.append( ">" ) - #args.append( "/dev/null" ) - - args[0] = "".join([TRINITY_BASE_DIR, '/', args[0]]); - - cmdline = " ".join(args) - - - - try: - # Run program - err_capture = open("stderr.txt", 'w') - proc = subprocess.Popen( args=cmdline, shell=True, stderr=err_capture, stdout=sys.stdout ) - returncode = proc.wait() - err_capture.close() - - - if returncode != 0: - raise Exception - - except Exception: - # Running Grinder failed: write error message to stderr - err_text = open("stderr.txt").readlines() - stop_err( "ERROR:\n" + "\n".join(err_text)) - - -if __name__ == "__main__": __main__() |