0
|
1 <tool id="cfsan_snp_pipeline_map_reads" name="CFSAN SNP Pipeline: map reads" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="@PROFILE@">
|
|
2 <description></description>
|
|
3 <macros>
|
|
4 <import>macros.xml</import>
|
|
5 </macros>
|
|
6 <expand macro="requirements"/>
|
|
7 <command detect_errors="exit_code"><![CDATA[
|
|
8 #set compressed =" False"
|
|
9 #if str($input_type_cond.input_type) == 'paired':
|
|
10 #set forward = $input_type_cond.reads_collection.forward
|
|
11 #set reverse = $input_type_cond.reads_collection.reverse
|
|
12 #end if
|
|
13 #if $forward.is_of_type("fastq.gz","fastqsanger.gz"):
|
|
14 ln -s '$forward' forward.gz &&
|
|
15 #set forward = 'forward.gz'
|
|
16 #set compressed = "GZ"
|
|
17 #else if $forward.is_of_type("fastq.bz2", "fastqsanger.bz2"):
|
|
18 ln -s '$forward' forward.bz2 &&
|
|
19 #set forward = 'forward.bz2'
|
|
20 #set compressed = "BZ2"
|
|
21 #end if
|
|
22 #if $reverse.is_of_type("fastq.gz","fastqsanger.gz"):
|
|
23 ln -s '$reverse' reverse.gz &&
|
|
24 #set reverse = 'reverse.gz'
|
|
25 #set compressed = "GZ"
|
|
26 #else if $reverse.is_of_type("fastq.bz2", "fastqsanger.bz2"):
|
|
27 ln -s '$reverse' reverse.bz2 &&
|
|
28 #set reverse = 'reverse.bz2'
|
|
29 #set compressed = "BZ2"
|
|
30 #end if
|
|
31 bowtie2-build '$reference' --threads \${GALAXY_SLOTS:-4} 'reference' &&
|
|
32 bowtie2 -q -x reference -1 '$forward' -2 '$reverse' -p \${GALAXY_SLOTS:-4} --reorder -X 1000 -S '$output'
|
|
33 ]]></command>
|
|
34 <inputs>
|
|
35 <conditional name="input_type_cond">
|
|
36 <param name="input_type" type="select" label="Choose the category of the files to be analyzed">
|
|
37 <option value="paired" selected="true">List of dataset pairs</option>
|
|
38 <option value="pair">Dataset pair</option>
|
|
39 </param>
|
|
40 <when value="pair">
|
|
41 <param name="forward" type="data" format="fastqsanger.gz,fastqsanger" label="Read1 fastq file"/>
|
|
42 <param name="reverse" type="data" format="fastqsanger.gz,fastqsanger" label="Read2 fastq file"/>
|
|
43 </when>
|
|
44 <when value="paired">
|
|
45 <param name="reads_collection" type="data_collection" format="fastqsanger,fastqsanger.gz" collection_type="paired" label="Collection of fastqsanger paired read files"/>
|
|
46 </when>
|
|
47 </conditional>
|
|
48 <expand macro="reference_cond"/>
|
|
49 </inputs>
|
|
50 <outputs>
|
|
51 <data name="output" format="sam"/>
|
|
52 </outputs>
|
|
53 <tests>
|
|
54 <test>
|
|
55 <param name="reference" value="lambda_virus.fasta" ftype="fasta"/>
|
|
56 <param name="input_type" value="pair"/>
|
|
57 <param name="forward" value="sample1_1.fastq.gz" ftype="fastqsanger.gz"/>
|
|
58 <param name="reverse" value="sample1_2.fastq.gz" ftype="fastqsanger.gz"/>
|
|
59 <output name="output" ftype="sam">
|
|
60 <assert_contents>
|
|
61 <has_size value="7285613" delta="1000"/>
|
|
62 </assert_contents>
|
|
63 </output>
|
|
64 </test>
|
|
65 <test>
|
|
66 <param name="reference" value="lambda_virus.fasta" ftype="fasta"/>
|
|
67 <param name="input_type" value="paired"/>
|
|
68 <param name="reads_collection">
|
|
69 <collection type="paired">
|
|
70 <element name="forward" value="sample1_1.fastq.gz"/>
|
|
71 <element name="reverse" value="sample1_2.fastq.gz"/>
|
|
72 </collection>
|
|
73 </param>
|
|
74 <output name="output" ftype="sam">
|
|
75 <assert_contents>
|
|
76 <has_size value="7285613" delta="1000"/>
|
|
77 </assert_contents>
|
|
78 </output>
|
|
79 </test>
|
|
80 </tests>
|
|
81 <help><![CDATA[
|
|
82 **What it does**
|
|
83
|
|
84 Aligns the sequence reads for a specified sample to a specified reference genome. The reads are
|
|
85 sorted, duplicates marked, and realigned around indels.
|
|
86
|
|
87 **More information**
|
|
88
|
|
89 CFSAN SNP Pipeline `call consensus documentation <https://snp-pipeline.readthedocs.io/en/latest/cmd_ref.html#call-consensus>`_
|
|
90 ]]></help>
|
|
91 <expand macro="citations"/>
|
|
92 </tool>
|
|
93
|