annotate sampleFasta.xml @ 12:6b7d31026d1c draft

Uploaded
author petr-novak
date Tue, 04 Feb 2020 08:38:22 -0500
parents c2c69c6090f0
children a675b4534b19
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
9
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
1 <tool id="sampler" name="Read sampling" version="1.0.0">
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
2 <description> Tool for random sampling subsets of reads from larger dataset</description>
3
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
3 <requirements>
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
4 <requirement type="package">seqkit</requirement>
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
5 </requirements>
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
6 <stdio>
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
7 <exit_code range="1:" level="fatal" description="Error" />
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
8 </stdio>
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
9 <command>
9
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
10 <![CDATA[
3
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
11 #if str($paired)=="true"
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
12 ${__tool_directory__}/deinterlacer.py $input Afile Bfile
9
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
13 &&
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
14 seqkit sample -2 --number $number --rand-seed $seed -o Asample -w 0 Afile < /dev/null
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
15 &&
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
16 seqkit sample -2 --number $number --rand-seed $seed -o Bsample -w 0 Bfile < /dev/null
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
17 &&
3
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
18 ${__tool_directory__}/fasta_interlacer.py -a Asample -b Bsample -p $output -x tmpfile
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
19 #else
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
20 seqkit sample -2 --number $number --rand-seed $seed -o $output -w 0 $input
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
21 #end if
9
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
22 ]]>
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
23 </command>
3
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
24
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
25 <inputs>
9
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
26 <param format="fasta" type="data" name="input" label="Read file (FASTA)" />
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
27 <param name="number" type="integer" size="7" value="500000" min="1" label="Number of reads or read pairs"/>
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
28 <param name="seed" type="integer" size="10" value="10" min="0" label="Random number generator seed " />
c2c69c6090f0 Uploaded
petr-novak
parents: 3
diff changeset
29 <param name="paired" type="boolean" truevalue="true" falsevalue="false" checked="False" label="Paired-end reads" help="If paired-end reads are sampled, left and right-hand reads must be interlaced and all pairs must be complete."/>
3
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
30
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
31
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
32 </inputs>
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
33
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
34
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
35 <outputs>
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
36 <data format="fasta" name="output" label="Random selection from dataset ${input.hid}, sample size ${number})" />
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
37 </outputs>
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
38
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
39 <help>
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
40 **What it does**
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
41
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
42 This tools is intended to create sample of sequences from by taking 'random' sample from larger data sets.
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
43 Using a same seed parameter make sampling reproducible.
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
44
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
45
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
46 </help>
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
47
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
48
e320ef2d105a Uploaded
petr-novak
parents:
diff changeset
49 </tool>