Mercurial > repos > iuc > sra_tools
comparison fastq_dump.xml @ 0:b723c120161a draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/sra-tools commit d555f296be01d0c0fa5ac28d28a48cf4ada98297
author | iuc |
---|---|
date | Sun, 06 Dec 2015 09:04:37 -0500 |
parents | |
children | 462ee06c9358 |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:b723c120161a |
---|---|
1 <tool id="fastq_dump" name="Extract reads" version="1.2.5"> | |
2 <description>in FASTQ/A format from NCBI SRA.</description> | |
3 <macros> | |
4 <import>sra_macros.xml</import> | |
5 </macros> | |
6 <expand macro="requirements"/> | |
7 <stdio> | |
8 <exit_code range="127" level="fatal" description="Could not locate fastq-dump binary"/> | |
9 </stdio> | |
10 <version_command>fastq-dump --version</version_command> | |
11 <command> | |
12 <![CDATA[ | |
13 ## Need to set the home directory to the current working directory, | |
14 ## else the tool tries to write to home/.ncbi and fails when used | |
15 ## with a cluster manager. | |
16 export HOME=\$PWD && | |
17 vdb-config --restore-defaults && | |
18 #if $input.input_select == "file": | |
19 fastq-dump --log-level fatal --accession '${input.file.name}' | |
20 #else: | |
21 vdb-config -s "/repository/user/main/public/root=\$PWD" && | |
22 ## Do not use prefetch if region is specified, to avoid downloading | |
23 ## the complete sra file. | |
24 #if ( str( $adv.region ) == "" ) and ( str( $adv.minID ) == "" ) and ( str( $adv.maxID ) == "" ): | |
25 ASCP_PATH=`command -v ascp` && | |
26 ASCP_KEY=`dirname \$ASCP_PATH`/asperaweb_id_dsa.openssh || true && | |
27 prefetch --ascp-path "\$ASCP_PATH|\$ASCP_KEY" $input.accession && | |
28 ## Duplicate vdb-config, in case settings changed between prefetch and | |
29 ## dump command. | |
30 vdb-config -s "/repository/user/main/public/root=\$PWD" && | |
31 #end if | |
32 fastq-dump --accession "$input.accession" | |
33 #end if | |
34 --defline-seq '@\$sn[_\$rn]/\$ri' | |
35 --stdout | |
36 $adv.split | |
37 #if str( $adv.alignments ) == "aligned": | |
38 --aligned | |
39 #end if | |
40 #if str( $adv.alignments ) == "unaligned": | |
41 --unaligned | |
42 #end if | |
43 #if str( $adv.minID ) != "": | |
44 --minSpotId "$adv.minID" | |
45 #end if | |
46 #if str( $adv.maxID ) != "": | |
47 --maxSpotId "$adv.maxID" | |
48 #end if | |
49 #if str( $adv.minlen ) != "": | |
50 --minReadLen "$adv.minlen" | |
51 #end if | |
52 #if str( $adv.readfilter ) != "": | |
53 --read-filter "$adv.readfilter" | |
54 #end if | |
55 #if str( $adv.region ) != "": | |
56 --aligned-region "$adv.region" | |
57 #end if | |
58 #if str( $adv.spotgroups ) != "": | |
59 --spot-groups "$adv.spotgroups" | |
60 #end if | |
61 #if str( $adv.matepairDist ) != "": | |
62 --matepair-distance "$adv.matepairDist" | |
63 #end if | |
64 $adv.clip | |
65 $adv.skip_technical | |
66 #if str( $outputformat ) == "fasta": | |
67 --fasta | |
68 #end if | |
69 #if $input.input_select=="file": | |
70 "$input.file" > "$output_file" | |
71 #else: | |
72 "$input.accession" > "$output_accession" | |
73 #end if | |
74 ]]> | |
75 </command> | |
76 <inputs> | |
77 <expand macro="input_conditional"/> | |
78 <param name="outputformat" type="select" label="select output format"> | |
79 <option value="fastqsanger">fastq</option> | |
80 <option value="fasta">fasta</option> | |
81 </param> | |
82 <section name="adv" title="Advanced Options" expanded="False"> | |
83 <param name="minID" type="integer" label="minimum spot ID" optional="true"/> | |
84 <param name="maxID" type="integer" label="maximum spot ID" optional="true"/> | |
85 <param name="minlen" type="integer" label="minimum read length" optional="true"/> | |
86 <param name="split" type="boolean" checked="true" truevalue="--split-spot" falsevalue=""> | |
87 <label>split spot by read pairs</label> | |
88 </param> | |
89 <expand macro="alignments"/> | |
90 <expand macro="region"/> | |
91 <expand macro="matepairDist"/> | |
92 <param name="readfilter" type="select" value=""> | |
93 <label>filter by value</label> | |
94 <option value="">None</option> | |
95 <option value="pass">pass</option> | |
96 <option value="reject">reject</option> | |
97 <option value="criteria">criteria</option> | |
98 <option value="redacted">redacted</option> | |
99 </param> | |
100 <param name="spotgroups" type="text" label="filter by spot-groups" optional="true"/> | |
101 <param name="clip" type="boolean" truevalue="--clip" falsevalue=""> | |
102 <label>apply left and right clips</label> | |
103 </param> | |
104 <param name="skip_technical" type="boolean" truevalue="--skip-technical" falsevalue="" checked="False" label="Dump only biological reads"/> | |
105 </section> | |
106 </inputs> | |
107 <outputs> | |
108 <data format="fastq" name="output_accession" label="${input.accession}.${outputformat}"> | |
109 <filter>input['input_select'] == "accession_number"</filter> | |
110 <change_format> | |
111 <when input="outputformat" value="fasta" format="fasta"/> | |
112 </change_format> | |
113 </data> | |
114 <data format="fastq" name="output_file" label="${input.file.name}.${outputformat}"> | |
115 <filter>input['input_select'] == "file"</filter> | |
116 <change_format> | |
117 <when input="outputformat" value="fasta" format="fasta"/> | |
118 </change_format> | |
119 </data> | |
120 </outputs> | |
121 <tests> | |
122 <test> | |
123 <param name="input_select" value="accession_number"/> | |
124 <param name="outputformat" value="fastqsanger"/> | |
125 <param name="accession" value="SRR044777"/> | |
126 <param name="skip_technical" value="True"/> | |
127 <output name="output_accession"> | |
128 <assert_contents> | |
129 <not_has_text text="rRNA_primer"/> | |
130 <has_text text="F47USSH02GNP1D" /> | |
131 </assert_contents> | |
132 </output> | |
133 </test> | |
134 <test> | |
135 <param name="input_select" value="accession_number"/> | |
136 <param name="outputformat" value="fastqsanger"/> | |
137 <param name="accession" value="SRR925743"/> | |
138 <param name="maxID" value="5"/> | |
139 <output name="output_accession" file="fastq_dump_result.fastq" ftype="fastq"/> | |
140 </test> | |
141 </tests> | |
142 <help> | |
143 This tool extracts reads from SRA archives using fastq-dump. | |
144 The fastq-dump program is developed at NCBI, and is available at | |
145 http://www.ncbi.nlm.nih.gov/Traces/sra/sra.cgi?view=software. | |
146 @SRATOOLS_ATTRRIBUTION@ | |
147 </help> | |
148 <expand macro="citation"/> | |
149 </tool> |