comparison fastq_subsampling.xml @ 0:bc23da9d464c draft default tip

planemo upload for repository http://172.20.124.12:3000/bvalot3/PythonScript commit 9676573ee48ce5343600ab45cd3ac1a6adddabe4
author bvalot
date Tue, 14 Jun 2022 08:15:55 +0000
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:bc23da9d464c
1 <tool id="fastq_subsampling_wrapper" name="Fastq subsampling" version="0.1">
2 <description></description>
3 <requirements>
4 <requirement type="package" version="0.15">pysam</requirement>
5 </requirements>
6 <stdio>
7 <exit_code range="1:" level="fatal" />
8 </stdio>
9 <version_command>$__tool_directory__/fastq_subsampling.py -v</version_command>
10 <command>
11 $__tool_directory__/fastq_subsampling.py
12 --galaxy
13 #if $fastq.choice == "choice1"
14 -s '${fastq.single}'
15 #end if
16 #if $fastq.choice == "choice2"
17 -r '${fastq.forward}'
18 -l '${fastq.reverse}'
19 #end if
20 #if $fastq.choice == "choice3"
21 -r '${fastq.pairedfile.forward}'
22 -l '${fastq.pairedfile.reverse}'
23 #end if
24 #if str($coverage)
25 -c $coverage
26 #end if
27 $size
28 &amp;> '$logfile'
29 </command>
30 <inputs>
31 <conditional name="fastq" >
32 <param name="choice" type="select" label="Type of reads to subsampling" help="" >
33 <option value="choice1" selected="true">Single</option>
34 <option value="choice2">Paired (separated)</option>
35 <option value="choice3">Paired</option>
36 </param>
37 <when value="choice1">
38 <param name="single" type="data" format="fastq,fastq.gz"
39 label="Single read file" help="Fastq(gz) format" />
40 </when>
41 <when value="choice2">
42 <param name="forward" type="data" format="fastq,fastq.gz"
43 label="Forward read file" help="Fastq(gz) format" />
44 <param name="reverse" type="data" format="fastq,fastq.gz"
45 label="Reverse read file" help="Fastq(gz) format" />
46 </when>
47 <when value="choice3">
48 <param name="pairedfile" type="data_collection" format="fastq,fastq.gz"
49 label="Paired of read files" help="Fastq(gz) format"
50 collection_type="paired" />
51 </when>
52 </conditional>
53 <param name="size" type="integer" optional="false" value="6000000"
54 label="Size of the genome in bp" />
55 <param name="coverage" type="integer" value="40" optional="true"
56 label="Mean coverage to sampling" />
57 </inputs>
58
59 <outputs>
60 <data name="logfile" format="txt" label="${tool.name} on ${on_string}: log" />
61 <data name="singleout" format="fastqsanger.gz"
62 label="${tool.name} on ${fastq.single.name}"
63 from_work_dir="1.fastq.gz">
64 <filter>fastq['choice'] == "choice1"</filter>
65 </data>
66 <data name="forwardout" format="fastqsanger.gz"
67 label="${tool.name} on ${fastq.forward.name}"
68 from_work_dir="1.fastq.gz">
69 <filter>fastq['choice'] == "choice2"</filter>
70 </data>
71 <data name="reverseout" format="fastqsanger.gz"
72 label="${tool.name} on ${fastq.reverse.name}"
73 from_work_dir="2.fastq.gz">
74 <filter>fastq['choice'] == "choice2"</filter>
75 </data>
76 <collection name="paired_output" type="paired"
77 label="${tool.name} on ${fastq.pairedfile.name}">
78 <data name="forward" format="fastqsanger.gz"
79 from_work_dir="1.fastq.gz">
80 </data>
81 <data name="reverse" format="fastqsanger.gz"
82 from_work_dir="2.fastq.gz">
83 </data>
84 <filter>fastq['choice'] == "choice3"</filter>
85 </collection>
86 </outputs>
87 <tests>
88 <test expect_num_outputs="3">
89 <param name="choice" value="choice2" />
90 <param name="forward" value="input_R1.fastq.gz" />
91 <param name="reverse" value="input_R2.fastq.gz" />
92 </test>
93 </tests>
94 <help>
95 **What it does**
96
97 Subsampling a single or a paired of fastq(.gz) file to a given coverage
98
99 **License and citation**
100
101 This Galaxy tool is Copyright © 2018 `B. Valot` and is released under the `GPL3 license`.
102
103 </help>
104 <citations>
105 </citations>
106 </tool>