comparison alleyoop.xml @ 1:57bf9a0d49a5 draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/slamdunk commit dbd131d3a162e9d70c305148d305680acb549e93
author iuc
date Sun, 20 Jan 2019 06:51:15 -0500
parents
children 141f65f7c7c8
comparison
equal deleted inserted replaced
0:3fd7458bc861 1:57bf9a0d49a5
1 <tool id="alleyoop" name="Alleyoop" version="@TOOL_VERSION@">
2 <description>- post-processing and QC of Slamdunk analyses</description>
3 <macros>
4 <import>macros.xml</import>
5 </macros>
6 <expand macro="requirements" />
7 <version_command>alleyoop --version</version_command>
8 <command detect_errors="exit_code"><![CDATA[
9 #import re
10
11 #if $reference_source.reference_source_selector == 'history':
12 ln -f -s '$reference_source.ref_file' reference.fa &&
13 #else:
14 ln -f -s '$reference_source.ref_file.fields.path' reference.fa &&
15 #end if
16
17 mkdir ./filter &&
18 #for $bam in $reads:
19 #set $ext = ""
20 #set $bam_name = re.sub('[^\w\-\.]', '_', str($bam.element_identifier))
21 #if not $bam_name.endswith('.bam')
22 #set $ext = ".bam"
23 #end if
24 ln -s '$bam' './filter/${bam_name}${ext}' &&
25 ln -s '$bam.metadata.bam_index' './filter/${bam_name}${ext}.bai' &&
26 #end for
27
28 mkdir ./count &&
29 #for $tsv in $count_tsvs:
30 #set $ext = ""
31 #set $tsv_name = re.sub('[^\w\-\.]', '_', str($tsv.element_identifier))
32 #if not $tsv_name.endswith('_tcount.tsv')
33 #set $ext = "_tcount.tsv"
34 #end if
35 ln -s '$tsv' './count/${tsv_name}${ext}' &&
36 #end for
37
38 mkdir ./snp &&
39 #for $vcf in $variants:
40 #set $ext = ""
41 #set $vcf_name = re.sub('[^\w\-\.]', '_', str($vcf.element_identifier))
42 #if not $vcf_name.endswith('_snp.vcf')
43 #set $ext = "_snp.vcf"
44 #end if
45 ln -s '$vcf' './snp/${vcf_name}${ext}' &&
46 #end for
47
48 alleyoop summary -o ./summary.txt -t ./count ./filter/*bam &&
49
50 alleyoop rates -o ./stats -r reference.fa -mq $mq ./filter/*bam &&
51
52 alleyoop utrrates -o ./stats -r reference.fa -b $Reference -t \${GALAXY_SLOTS:-1} -l $l -mq $mq ./filter/*bam &&
53
54 alleyoop tcperreadpos -o ./stats -r reference.fa -s ./snp -t \${GALAXY_SLOTS:-1} -l $l -mq $mq ./filter/*bam &&
55
56 alleyoop tcperutrpos -o ./stats -r reference.fa -s ./snp -t \${GALAXY_SLOTS:-1} -l $l -b $Reference -mq $mq ./filter/*bam
57
58 #if $bams:
59 && alleyoop read-separator -o ./splitbams -s ./snp -r reference.fa ./filter/*bam
60 #end if
61
62 ]]></command>
63 <inputs>
64 <expand macro="reference_files" />
65 <param name="reads" type="data" format="sam,bam" multiple="True" label="Slamdunk BAM files" />
66 <param name="count_tsvs" type="data" format="tabular" multiple="True" label="Slamdunk Count TSV files" />
67 <param name="variants" type="data" format="vcf" multiple="True" label="Slamdunk VCF files" />
68 <param argument="-mq" type="integer" label="Minimum base quality"
69 value="27" min="0"
70 help="Minimum base quality for T>C conversions (default: 27)." />
71 <param argument="-l" type="integer" label="Read length"
72 value="50" min="50" help="Maximum read length (before trimming)." />
73 <param name="bams" type="boolean" truevalue="True" falsevalue="False" checked="False" label="Output T>C separated BAM files?" help="If this option is set to Yes, the Alleyoop read-separator module will be run to output BAM files of separated T>C reads from non T>C reads. Default: No"/>
74 </inputs>
75 <outputs>
76 <collection name="outputSummary" type="list" label="${tool.name} on ${on_string}: Summary tables">
77 <discover_datasets pattern="(?P&lt;name&gt;.+)\.txt$" format="tabular" directory="." visible="false" />
78 </collection>
79 <collection name="outputStats" type="list" label="${tool.name} on ${on_string}: Stats tables">
80 <discover_datasets pattern="(?P&lt;name&gt;.+)\.csv$" format="tabular" directory="./stats" visible="false" />
81 </collection>
82 <collection name="outputTCReads" type="list" label="${tool.name} on ${on_string}: TC Reads">
83 <discover_datasets pattern="(?P&lt;name&gt;.+)_TCReads.bam$" format="bam" directory="./splitbams" visible="false" />
84 <filter>bams</filter>
85 </collection>
86 <collection name="outputbkgdReads" type="list" label="${tool.name} on ${on_string}: Background Reads">
87 <discover_datasets pattern="(?P&lt;name&gt;.+)_backgroundReads.bam$" format="bam" directory="./splitbams" visible="false" />
88 <filter>bams</filter>
89 </collection>
90 </outputs>
91 <tests>
92 <!-- Ensure default output works -->
93 <test expect_num_outputs="2">
94 <param name="reference_source_selector" value="history" />
95 <param name="ref_file" ftype="fasta" value="ref.fa" />
96 <param name="Reference" ftype="bed" value="actb.bed" />
97 <param name="reads" ftype="bam" value="reads1.bam,reads2.bam" />
98 <param name="count_tsvs" ftype="tabular" value="reads1_tcount.tsv,reads2_tcount.tsv" />
99 <param name="variants" ftype="vcf" value="reads1_snp.vcf,reads2_snp.vcf" />
100 <param name="l" value="100" />
101 <param name="mq" value="27" />
102 <output_collection name="outputSummary" count="2">
103 <element name="summary" ftype="tabular" file="summary.txt" />
104 </output_collection>
105 <output_collection name="outputStats" count="8">
106 <element name="reads1_overallrates" ftype="tabular" file="reads1_overallrates.csv" />
107 </output_collection>
108 </test>
109 <!-- Ensure BAM output works -->
110 <test expect_num_outputs="4">
111 <param name="reference_source_selector" value="history" />
112 <param name="ref_file" ftype="fasta" value="ref.fa" />
113 <param name="Reference" ftype="bed" value="actb.bed" />
114 <param name="reads" ftype="bam" value="reads1.bam,reads2.bam" />
115 <param name="count_tsvs" ftype="tabular" value="reads1_tcount.tsv,reads2_tcount.tsv" />
116 <param name="variants" ftype="vcf" value="reads1_snp.vcf,reads2_snp.vcf" />
117 <param name="l" value="100" />
118 <param name="mq" value="27" />
119 <param name="bams" value="True" />
120 <output_collection name="outputTCReads" count="2">
121 <element name="reads1" ftype="bam" file="reads1_TCReads.bam" />
122 </output_collection>
123 <output_collection name="outputbkgdReads" count="2">
124 <element name="reads1" ftype="bam" file="reads1_backgroundReads.bam" />
125 </output_collection>
126 </test>
127 </tests>
128 <help><![CDATA[
129 SLAMseq
130 =======
131
132 SLAMseq is a novel sequencing protocol that directly uncovers 4-thiouridine incorporation events in RNA by high-throughput sequencing. When combined with metabolic labeling protocols, SLAM-seq allows to study the intracellular RNA dynamics, from transcription, RNA processing to RNA stability.
133
134 Original publication: `Herzog et al., Nature Methods, 2017; doi:10.1038/nmeth.4435 <https://www.nature.com/nmeth/journal/vaop/ncurrent/full/nmeth.4435.html>`_
135
136 Alleyoop
137 ========
138
139 Alleyoop (Additional sLamdunk heLpEr tools for anY diagnOstics Or Plots) is a collection of tools for post-processing and running diagnostics on Slamdunk analyses. This tool works on the output of the **Slamdunk** tool and requires all the inputs listed in the table below.
140
141 =============== ==========================================================================================================================================================
142 Parameter Description
143 =============== ==========================================================================================================================================================
144 **Genome** The reference fasta file (Genome assembly).
145 **Reference** BED-file containing coordinates for 3' UTRs.
146 **Reads** Slamdunk Filtered BAM files.
147 **Counts** Slamdunk Count TSV files.
148 **Variants** Slandunk VCF files.
149 **Read length** Maximum length of reads (usually 50, 100, 150).
150 =============== ==========================================================================================================================================================
151
152 This tool runs the **Alleyoop** *summary*, *rates*, *utrrates*, *tcperreadpos* and *tcperutrpos* modules and outputs:
153
154 * Tab-separated *summary* files from the summary module with mapping and PCA statistics
155 * Tab-separated *stats* files from the rates, utrrates, tcperreadpos and tcperutrpos modules
156
157 Optionally, the *read-separator* module can be run to output BAM files of separated T>C and non T>C reads.
158
159 The summary and stats files can be summarised and visualised with MultiQC. An example MultiQC report can be seen here_. For information on these modules see the `Alleyoop documentation`_.
160
161 .. _`Alleyoop documentation`: http://t-neumann.github.io/slamdunk/docs.html#document-Alleyoop
162 .. _here: http://t-neumann.github.io/slamdunk/multiqc_example/multiqc_report.html
163
164 ]]></help>
165 <citations>
166 <expand macro="citations" />
167 </citations>
168 </tool>