comparison convert.xml @ 4:ffee8534a5c4

upgrade to mimodd version 0.1.6
author Wolfgang Maier
date Thu, 04 Jun 2015 17:52:04 +0200
parents 72d20758ba2c
children bdd1995c9e66
comparison
equal deleted inserted replaced
3:ba685c655e18 4:ffee8534a5c4
4 <import>toolshed_macros.xml</import> 4 <import>toolshed_macros.xml</import>
5 </macros> 5 </macros>
6 <expand macro="requirements"/> 6 <expand macro="requirements"/>
7 <version_command>mimodd version -q</version_command> 7 <version_command>mimodd version -q</version_command>
8 <command> 8 <command>
9 #if $str($mode.split_on_rgs) or $str($mode.oformat)=="fastq" or $str($mode.oformat)=="gz":
10 echo "Your input data is now getting processed by MiModD. The output will be split into several files based on the read groups found in the input.\nThis history item will remain in the busy state until the job is finished.\nAfter the job is showing as finished, Galaxy will start adding the results files to your history one by one.\n\nThis may take a while to complete! \n\nYou should refresh your history to see if new files have arrived.\n\nThis message is for your information only and can be deleted from the history once the job has finished." > $output_split_on_read_groups;
11
12 mkdir converted_data;
13 #end if
14
9 mimodd convert 15 mimodd convert
10 16
11 #for $i in $mode.input_list 17 #for $i in $mode.input_list
12 "${i.file1}" 18 "${i.file1}"
13 #if $str($mode.iformat) in ("fastq_pe", "gz_pe"): 19 #if $str($mode.iformat) in ("fastq_pe", "gz_pe"):
15 #end if 21 #end if
16 #end for 22 #end for
17 #if $str($mode.header) != "None": 23 #if $str($mode.header) != "None":
18 --header "$(mode.header)" 24 --header "$(mode.header)"
19 #end if 25 #end if
20 --ofile "$outputname" 26
27 #if $str($outputname) == "None":
28 --ofile converted_data/read_group
29 #else
30 --ofile "$outputname"
31 #end if
21 --iformat $(mode.iformat) 32 --iformat $(mode.iformat)
22 --oformat $(mode.oformat) 33 --oformat $(mode.oformat)
34 ${mode.split_on_rgs}
23 </command> 35 </command>
24 36
25 <inputs> 37 <inputs>
26 <conditional name="mode"> 38 <conditional name="mode">
27 <param name="iformat" type="select" label="input file format" help="Your choice will update the interface to display further choices appropriate for your type of input data."> 39 <param name="iformat" type="select" label="input file format" help="Your choice will update the interface to display further choices appropriate for your type of input data.">
28 <option value="fastq">fastq: single-end (one file)</option> 40 <option value="fastq">fastq: single-end (one file)</option>
29 <option value="fastq_pe">fastq: paired-end (two files)</option> 41 <option value="fastq_pe">fastq: paired-end (two files)</option>
30 <option value="gz">gzip compressed fastq: single-end (one file)</option> 42 <option value="gz">gzip compressed fastq: single-end (one file)</option>
31 <option value="gz_pe">gzip compressed fastq: paired-end (two files)</option> 43 <option value="gz_pe">gzip compressed fastq: paired-end (two files)</option>
32 <option value="sam">sam</option> 44 <option value="sam">sam</option>
33 <option value="bam">bam</option> 45 <option value="bam">bam</option>
34 </param> 46 </param>
35 <when value="fastq"> 47 <when value="fastq">
36 <param name="oformat" type="select" label="output file format"> 48 <param name="oformat" type="select" label="output file format">
37 <option value="sam">sam</option> 49 <option value="sam">sam</option>
38 <option value="bam">bam</option> 50 <option value="bam">bam</option>
39 </param> 51 </param>
40 <repeat name="input_list" title="fastq input dataset" default="1" min="1"> 52 <repeat name="input_list" title="fastq input dataset" default="1" min="1">
41 <param name="file1" format="fastq" type="data" label="inputfile"/> 53 <param name="file1" format="fastq" type="data" label="inputfile"/>
42 </repeat> 54 </repeat>
43 <param name="header" type="data" format="sam" label="Use Header File" help="A SAM file with header information, as generated, for example, by the NGS Run Annotation Tool, that will be used to attach metainformation to the results file."/> 55 <param name="header" type="data" format="sam" label="Use Header File" help="A SAM file with header information, as generated, for example, by the NGS Run Annotation Tool, that will be used to attach metainformation to the results file."/>
56 <param name="split_on_rgs" type="hidden" value=""/>
44 </when> 57 </when>
45 <when value="fastq_pe"> 58 <when value="fastq_pe">
46 <param name="oformat" type="select" label="output file format"> 59 <param name="oformat" type="select" label="output file format">
47 <option value="sam">sam</option> 60 <option value="sam">sam</option>
48 <option value="bam">bam</option> 61 <option value="bam">bam</option>
49 </param> 62 </param>
50 <repeat name="input_list" title="fastq input datasets" default="1" min="1"> 63 <repeat name="input_list" title="fastq input datasets" default="1" min="1">
51 <param format="fastq" name="file1" type="data" label="inputfile with the first set of reads of paired-end data"/> 64 <param format="fastq" name="file1" type="data" label="inputfile with the first set of reads of paired-end data"/>
52 <param format="fastq" name="file2" type="data" label="inputfile with the second set of reads of paired-end data"/> 65 <param format="fastq" name="file2" type="data" label="inputfile with the second set of reads of paired-end data"/>
53 </repeat> 66 </repeat>
54 <param name="header" type="data" format="sam" label="Use Header File" help="A SAM file with header information, as generated, for example, by the NGS Run Annotation Tool, that will be used to attach metainformation to the results file."/> 67 <param name="header" type="data" format="sam" label="Use Header File" help="A SAM file with header information, as generated, for example, by the NGS Run Annotation Tool, that will be used to attach metainformation to the results file."/>
68 <param name="split_on_rgs" type="hidden" value=""/>
55 </when> 69 </when>
56 <when value="gz"> 70 <when value="gz">
57 <param name="oformat" type="select" label="output file format"> 71 <param name="oformat" type="select" label="output file format">
58 <option value="sam">sam</option> 72 <option value="sam">sam</option>
59 <option value="bam">bam</option> 73 <option value="bam">bam</option>
60 </param> 74 </param>
61 <repeat name="input_list" title="fastq.gz input dataset" default="1" min="1"> 75 <repeat name="input_list" title="fastq.gz input dataset" default="1" min="1">
62 <param name="file1" format="data" type="data" label="inputfile"/> 76 <param name="file1" format="data" type="data" label="inputfile"/>
63 </repeat> 77 </repeat>
64 <param name="header" type="data" format="sam" label="Use Header File" help="A SAM file with header information, as generated, for example, by the NGS Run Annotation Tool, that will be used to attach metainformation to the results file."/> 78 <param name="header" type="data" format="sam" label="Use Header File" help="A SAM file with header information, as generated, for example, by the NGS Run Annotation Tool, that will be used to attach metainformation to the results file."/>
79 <param name="split_on_rgs" type="hidden" value=""/>
65 </when> 80 </when>
66 <when value="gz_pe"> 81 <when value="gz_pe">
67 <param name="oformat" type="select" label="output file format"> 82 <param name="oformat" type="select" label="output file format">
68 <option value="sam">sam</option> 83 <option value="sam">sam</option>
69 <option value="bam">bam</option> 84 <option value="bam">bam</option>
70 </param> 85 </param>
71 <repeat name="input_list" title="fastq.gz input datasets" default="1" min="1"> 86 <repeat name="input_list" title="fastq.gz input datasets" default="1" min="1">
72 <param format="data" name="file1" type="data" label="inputfile with the first set of reads of paired-end data"/> 87 <param format="data" name="file1" type="data" label="inputfile with the first set of reads of paired-end data"/>
73 <param format="data" name="file2" type="data" label="inputfile with the second set of reads of paired-end data"/> 88 <param format="data" name="file2" type="data" label="inputfile with the second set of reads of paired-end data"/>
74 </repeat> 89 </repeat>
75 <param name="header" type="data" format="sam" label="Use Header File" help="A SAM file with header information, as generated, for example, by the NGS Run Annotation Tool, that will be used to attach metainformation to the results file."/> 90 <param name="header" type="data" format="sam" label="Use Header File" help="A SAM file with header information, as generated, for example, by the NGS Run Annotation Tool, that will be used to attach metainformation to the results file."/>
91 <param name="split_on_rgs" type="hidden" value=""/>
76 </when> 92 </when>
77 <when value="sam"> 93 <when value="sam">
78 <param name="oformat" type="select" label="output file format"> 94 <param name="oformat" type="select" label="output file format">
79 <option value="bam">bam</option> 95 <option value="bam">bam</option>
96 <option value="sam">sam</option>
97 <option value="fastq">fastq</option>
98 <option value="gz">gzipped fastq</option>
80 </param> 99 </param>
81 <repeat name="input_list" title="sam input dataset" default="1" min="1" max="1"> 100 <repeat name="input_list" title="sam input dataset" default="1" min="1" max="1">
82 <param name="file1" format="sam" type="data" label="inputfile"/> 101 <param name="file1" format="sam" type="data" label="inputfile"/>
83 </repeat> 102 </repeat>
84 <param name="header" type="hidden" value="None"/> 103 <param name="header" type="hidden" value="None"/>
104 <param name="split_on_rgs" type="boolean" truevalue="--split-on-rgs" falsevalue="" checked="false" label="Split output based on read group IDs" help="If the input file contains reads from different read groups, write them to separate output files; implied automatically for conversions to fastq and gzipped fastq format"/>
85 </when> 105 </when>
86 <when value="bam"> 106 <when value="bam">
87 <param name="oformat" type="select" label="output file format"> 107 <param name="oformat" type="select" label="output file format">
88 <option value="sam">sam</option> 108 <option value="sam">sam</option>
109 <option value="bam">bam</option>
110 <option value="fastq">fastq</option>
111 <option value="gz">gzipped fastq</option>
89 </param> 112 </param>
90 <repeat name="input_list" title="bam input dataset" default="1" min="1" max="1"> 113 <repeat name="input_list" title="bam input dataset" default="1" min="1" max="1">
91 <param name="file1" format="bam" type="data" label="inputfile"/> 114 <param name="file1" format="bam" type="data" label="inputfile"/>
92 </repeat> 115 </repeat>
93 <param name="header" type="hidden" value="None"/> 116 <param name="header" type="hidden" value="None"/>
117 <param name="split_on_rgs" type="boolean" truevalue="--split-on-rgs" falsevalue="" checked="false" label="Split output based on read group IDs" help="If the input file contains reads from different read groups, write them to separate output files; implied automatically for conversions to fastq and gzipped fastq format"/>
94 </when> 118 </when>
95 </conditional> 119 </conditional>
96 </inputs> 120 </inputs>
97 121
98 <outputs> 122 <outputs>
99 <data name="outputname" format="bam" label="Converted reads from MiModd ${tool.name} on ${on_string}"> 123 <data name="outputname" format="bam" label="Converted reads from MiModd ${tool.name} on ${on_string}">
100 <change_format> 124 <change_format>
101 <when input="mode.oformat" value="sam" format="sam" /> 125 <when input="mode.oformat" value="sam" format="sam" />
102 </change_format> 126 </change_format>
127 <filter>
128 (not mode['split_on_rgs'] and mode['oformat'] not in ("fastq", "gz"))
129 </filter>
130 </data>
131
132 <data name="output_split_on_read_groups" format="txt" label="MiModD ${tool.name} run on ${on_string}">
133 <filter>
134 (mode['split_on_rgs'] or mode['oformat'] in ("fastq", "gz"))
135 </filter>
136 <discover_datasets pattern="__designation_and_ext__" directory="converted_data" visible="true" />
103 </data> 137 </data>
104 </outputs> 138 </outputs>
105 139
106 <help> 140 <help>
107 .. class:: infomark 141 .. class:: infomark
112 146
113 As input file types it can handle uncompressed or gzipped fastq, SAM or BAM format, which it can convert to SAM or BAM format. 147 As input file types it can handle uncompressed or gzipped fastq, SAM or BAM format, which it can convert to SAM or BAM format.
114 148
115 **Notes:** 149 **Notes:**
116 150
117 1) In its standard configuration Galaxy will decompress any .gz files during their upload, so the option to align gzipped fastq input is useful only with customized Galaxy instances or by using linked files as explained in our `recipe for using gzipped fastq files in Galaxy`_ from the `MiModD user guide`_. 151 1) In its standard configuration Galaxy will decompress any .gz files during their upload, so the option to convert gzipped fastq input is useful only with customized Galaxy instances or by using linked files as explained in our `recipe for using gzipped fastq files in Galaxy`_ from the `MiModD user guide`_.
118 152
119 2) The tool can convert fastq files representing data from paired-end sequencing runs to appropriate SAM/BAM format provided that the mate information is split over two fastq files in corresponding order. 153 2) The tool can convert fastq files representing data from paired-end sequencing runs to appropriate SAM/BAM format provided that the mate information is split over two fastq files in corresponding order.
120 154
121 **TIP:** If your paired-end data is arranged differently, you may look into the *fastq splitter* and *fastq de-interlacer* tools for Galaxy from the `Fastq Manipulation category`_ of the Galaxy Tool Shed to see if they can convert your files to the expected format. 155 **TIP:** If your paired-end data is arranged differently, you may look into the *fastq splitter* and *fastq de-interlacer* tools for Galaxy from the `Fastq Manipulation category`_ of the Galaxy Tool Shed to see if they can convert your files to the expected format.
122 156