comparison sam_pileup.xml @ 4:a3b4ad6858ff draft default tip

"planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/sam_pileup commit 8301d37348be25a038b3c63b049b1178d05f5003"
author devteam
date Thu, 06 Feb 2020 07:11:33 -0500
parents 3ff8935743a9
children
comparison
equal deleted inserted replaced
3:890d97772e2a 4:a3b4ad6858ff
1 <tool id="sam_pileup" name="Generate pileup" version="1.1.2"> 1 <tool id="sam_pileup" name="Generate pileup" version="1.1.3" profile="16.04">
2 <description>from BAM dataset</description> 2 <description>from BAM dataset</description>
3 <requirements> 3 <requirements>
4 <requirement type="package" version="0.1.16">samtools</requirement> 4 <requirement type="package" version="0.1.16">samtools</requirement>
5 </requirements> 5 </requirements>
6 <command interpreter="python"> 6 <command><![CDATA[
7 sam_pileup.py 7 ln -s '$input1' input1.bam &&
8 --input1=$input1 8 ln -s '${input1.metadata.bam_index}' 'input1.bam.bai' &&
9 --output=$output1 9 #if $refOrHistory.reference == 'history':
10 --ref=$refOrHistory.reference 10 ln -s '$refOrHistory.ownFile' reference.fasta &&
11 #if $refOrHistory.reference == "history": 11 samtools faidx reference.fasta &&
12 --ownFile=$refOrHistory.ownFile 12 #end if
13 #else: 13 samtools pileup
14 --index=${refOrHistory.index.fields.path} 14 #if $lastCol == 'yes':
15 #end if 15 -s
16 --bamIndex=${input1.metadata.bam_index} 16 #end if
17 --lastCol=$lastCol 17 #if $indels == 'yes':
18 --indels=$indels 18 -i
19 --mapCap=$mapCap 19 #end if
20 --consensus=$c.consensus 20 -M $mapCap
21 #if $c.consensus == "yes": 21 #if $c.consensus == 'yes':
22 --theta=$c.theta 22 -c
23 --hapNum=$c.hapNum 23 -T $c.theta
24 --fraction=$c.fraction 24 -N $c.hapNum
25 --phredProb=$c.phredProb 25 -r $c.fraction
26 #else: 26 -I $c.phredProb
27 --theta="None" 27 #end if
28 --hapNum="None" 28 -f
29 --fraction="None" 29 #if $refOrHistory.reference == 'indexed':
30 --phredProb="None" 30 '${refOrHistory.index.fields.path}'
31 #end if 31 #else:
32 </command> 32 reference.fasta
33 <inputs> 33 #end if
34 <conditional name="refOrHistory"> 34 input1.bam
35 <param name="reference" type="select" label="Will you select a reference genome from your history or use a built-in index?"> 35 > '$output1'
36 <option value="indexed">Use a built-in index</option> 36 ]]></command>
37 <option value="history">Use one from the history</option> 37 <inputs>
38 </param> 38 <conditional name="refOrHistory">
39 <when value="indexed"> 39 <param name="reference" type="select" label="Will you select a reference genome from your history or use a built-in index?">
40 <param name="input1" type="data" format="bam" label="Select the BAM file to generate the pileup file for"> 40 <option value="indexed">Use a built-in index</option>
41 <validator type="unspecified_build" /> 41 <option value="history">Use one from the history</option>
42 <validator type="dataset_metadata_in_data_table" table_name="fasta_indexes" metadata_name="dbkey" metadata_column="1" message="Sequences are not currently available for the specified build." /> 42 </param>
43 43 <when value="indexed">
44 <param name="input1" type="data" format="bam" label="Select the BAM file to generate the pileup file for">
45 <validator type="unspecified_build" />
46 <validator type="dataset_metadata_in_data_table" table_name="fasta_indexes" metadata_name="dbkey" metadata_column="1" message="Sequences are not currently available for the specified build." />
47 </param>
48 <param name="index" type="select" label="Using reference genome">
49 <options from_data_table="fasta_indexes">
50 <filter type="data_meta" ref="input1" key="dbkey" column="1" />
51 <validator type="no_options" message="No reference genome is available for the build associated with the selected input dataset" />
52 </options>
53 </param>
54 </when>
55 <when value="history">
56 <param name="input1" type="data" format="bam" label="Select the BAM file to generate the pileup file for" />
57 <param name="ownFile" argument="-f" type="data" format="fasta" label="Select a reference genome" />
58 </when>
59 </conditional>
60 <param name="lastCol" argument="-s" type="select" label="Whether or not to print the mapping quality as the last column" help="Makes the output easier to parse, but is space inefficient">
61 <option value="no">Do not print the mapping quality as the last column</option>
62 <option value="yes">Print the mapping quality as the last column</option>
44 </param> 63 </param>
45 <param name="index" type="select" label="Using reference genome"> 64 <param name="indels" argument="-i" type="select" label="Whether or not to print only output pileup lines containing indels">
46 <options from_data_table="fasta_indexes"> 65 <option value="no">Print all lines</option>
47 <filter type="data_meta" ref="input1" key="dbkey" column="1" /> 66 <option value="yes">Print only lines containing indels</option>
48 <validator type="no_options" message="No reference genome is available for the build associated with the selected input dataset" />
49 </options>
50 </param> 67 </param>
51 </when> 68 <param name="mapCap" argument="-M" type="integer" value="60" label="Where to cap mapping quality" />
52 <when value="history"> 69 <conditional name="c">
53 <param name="input1" type="data" format="bam" label="Select the BAM file to generate the pileup file for" /> 70 <param name="consensus" argument="-c" type="select" label="Call consensus according to MAQ model?">
54 <param name="ownFile" type="data" format="fasta" metadata_name="dbkey" label="Select a reference genome" /> 71 <option selected="true" value="no">No</option>
55 </when> 72 <option value="yes">Yes</option>
56 </conditional> 73 </param>
57 <param name="lastCol" type="select" label="Whether or not to print the mapping quality as the last column" help="Makes the output easier to parse, but is space inefficient"> 74 <when value="no" />
58 <option value="no">Do not print the mapping quality as the last column</option> 75 <when value="yes">
59 <option value="yes">Print the mapping quality as the last column</option> 76 <param name="theta" argument="-T" type="float" value="0.85" label="Theta parameter (error dependency coefficient) in the MAQ consensus calling model" />
60 </param> 77 <param name="hapNum" argument="-N" type="integer" value="2" label="Number of haplotypes in the sample" help="Greater than or equal to 2" />
61 <param name="indels" type="select" label="Whether or not to print only output pileup lines containing indels"> 78 <param name="fraction" argument="-r" type="float" value="0.001" label="Expected fraction of differences between a pair of haplotypes" />
62 <option value="no">Print all lines</option> 79 <param name="phredProb" argument="-I" type="integer" value="40" label="Phred probability of an indel in sequencing/prep" />
63 <option value="yes">Print only lines containing indels</option> 80 </when>
64 </param> 81 </conditional>
65 <param name="mapCap" type="integer" value="60" label="Where to cap mapping quality" /> 82 </inputs>
66 <conditional name="c"> 83 <outputs>
67 <param name="consensus" type="select" label="Call consensus according to MAQ model?"> 84 <data name="output1" format="tabular" label="${tool.name} on ${on_string}: converted pileup" />
68 <option selected="true" value="no">No</option> 85 </outputs>
69 <option value="yes">Yes</option> 86 <tests>
70 </param> 87 <test>
71 <when value="no" /> 88 <!--
72 <when value="yes"> 89 Bam to pileup command:
73 <param name="theta" type="float" value="0.85" label="Theta parameter (error dependency coefficient) in the MAQ consensus calling model" /> 90 samtools faidx chr_m.fasta
74 <param name="hapNum" type="integer" value="2" label="Number of haplotypes in the sample" help="Greater than or equal to 2" /> 91 samtools pileup -M 60 -f chr_m.fasta test-data/sam_pileup_in1.bam > sam_pileup_out1.pileup
75 <param name="fraction" type="float" value="0.001" label="Expected fraction of differences between a pair of haplotypes" /> 92 chr_m.fasta is the prefix of the index
76 <param name="phredProb" type="integer" value="40" label="Phred probability of an indel in sequencing/prep" /> 93 -->
77 </when> 94 <param name="reference" value="history" />
78 </conditional> 95 <param name="input1" value="sam_pileup_in1.bam" ftype="bam" />
79 </inputs> 96 <param name="ownFile" value="chr_m.fasta" ftype="fasta" dbkey="equCab2" />
80 <outputs> 97 <param name="lastCol" value="no" />
81 <data format="tabular" name="output1" label="${tool.name} on ${on_string}: converted pileup" /> 98 <param name="indels" value="no" />
82 </outputs> 99 <param name="mapCap" value="60" />
83 <tests> 100 <param name="consensus" value="no" />
84 <test> 101 <output name="output1" file="sam_pileup_out1.pileup" />
85 <!-- 102 </test>
86 Bam to pileup command: 103 <!--
87 samtools faidx chr_m.fasta 104 <test>
88 samtools pileup -M 60 -f chr_m.fasta test-data/sam_pileup_in1.bam > sam_pileup_out1.pileup 105 Bam to pileup command:
89 chr_m.fasta is the prefix of the index 106 samtools pileup -M 60 -c -T 0.85 -N 2 -r 0.001 -I 40 -f chr_m.fasta test-data/sam_pileup_in1.bam > sam_pileup_out2.pileup
90 --> 107 chr_m.fasta is the prefix of the index
91 <param name="reference" value="history" /> 108 <param name="reference" value="indexed" />
92 <param name="input1" value="sam_pileup_in1.bam" ftype="bam" /> 109 <param name="input1" value="sam_pileup_in1.bam" ftype="bam" dbkey="equCab2" />
93 <param name="ownFile" value="chr_m.fasta" ftype="fasta" dbkey="equCab2" /> 110 <param name="index" value="chr_m" />
94 <param name="lastCol" value="no" /> 111 <param name="lastCol" value="no" />
95 <param name="indels" value="no" /> 112 <param name="indels" value="no" />
96 <param name="mapCap" value="60" /> 113 <param name="mapCap" value="60" />
97 <param name="consensus" value="no" /> 114 <param name="consensus" value="yes" />
98 <output name="output1" file="sam_pileup_out1.pileup" /> 115 <param name="theta" value="0.85" />
99 </test> 116 <param name="hapNum" value="2" />
100 <test> 117 <param name="fraction" value="0.001" />
101 <!-- 118 <param name="phredProb" value="40" />
102 Bam to pileup command: 119 <output name="output1" file="sam_pileup_out2.pileup" />
103 samtools pileup -M 60 -c -T 0.85 -N 2 -r 0.001 -I 40 -f chr_m.fasta test-data/sam_pileup_in1.bam > sam_pileup_out2.pileup 120 </test>
104 chr_m.fasta is the prefix of the index 121 -->
105 --> 122 </tests>
106 <param name="reference" value="indexed" /> 123 <help><![CDATA[
107 <param name="input1" value="sam_pileup_in1.bam" ftype="bam" dbkey="equCab2" />
108 <param name="index" value="chr_m" />
109 <param name="lastCol" value="no" />
110 <param name="indels" value="no" />
111 <param name="mapCap" value="60" />
112 <param name="consensus" value="yes" />
113 <param name="theta" value="0.85" />
114 <param name="hapNum" value="2" />
115 <param name="fraction" value="0.001" />
116 <param name="phredProb" value="40" />
117 <output name="output1" file="sam_pileup_out2.pileup" />
118 </test>
119 </tests>
120 <help>
121
122 **What it does** 124 **What it does**
123 125
124 Uses SAMTools_' pileup command to produce a pileup dataset from a provided BAM dataset. It generates two types of pileup datasets depending on the specified options. If *Call consensus according to MAQ model?* option is set to **No**, the tool produces simple pileup. If the option is set to **Yes**, a ten column pileup dataset with consensus is generated. Both types of datasets are briefly summarized below. 126 Uses SAMTools_' pileup command to produce a pileup dataset from a provided BAM dataset. It generates two types of pileup datasets depending on the specified options. If *Call consensus according to MAQ model?* option is set to **No**, the tool produces simple pileup. If the option is set to **Yes**, a ten column pileup dataset with consensus is generated. Both types of datasets are briefly summarized below.
125 127
126 .. _SAMTools: http://samtools.sourceforge.net/samtools.shtml 128 .. _SAMTools: http://samtools.sourceforge.net/samtools.shtml
139 --------------------------------- 141 ---------------------------------
140 chrM 412 A 2 ., II 142 chrM 412 A 2 ., II
141 chrM 413 G 4 ..t, IIIH 143 chrM 413 G 4 ..t, IIIH
142 chrM 414 C 4 ...a III2 144 chrM 414 C 4 ...a III2
143 chrM 415 C 4 TTTt III7 145 chrM 415 C 4 TTTt III7
144 146
145 where:: 147 where::
146 148
147 Column Definition 149 Column Definition
148 ------- ---------------------------- 150 ------- ----------------------------
149 1 Chromosome 151 1 Chromosome
150 2 Position (1-based) 152 2 Position (1-based)
151 3 Reference base at that position 153 3 Reference base at that position
152 4 Coverage (# reads aligning over that position) 154 4 Coverage (# reads aligning over that position)
153 5 Bases within reads where (see Galaxy wiki for more info) 155 5 Bases within reads where (see Galaxy wiki for more info)
154 6 Quality values (phred33 scale, see Galaxy wiki for more) 156 6 Quality values (phred33 scale, see Galaxy wiki for more)
155 157
156 **Ten column pileup** 158 **Ten column pileup**
157 159
158 The `ten-column` (consensus_) pileup incorporates additional consensus information generated with *-c* option of *samtools pileup* command:: 160 The `ten-column` (consensus_) pileup incorporates additional consensus information generated with *-c* option of *samtools pileup* command::
159 161
160 162
180 9 Bases within reads where (see Galaxy wiki for more info) 182 9 Bases within reads where (see Galaxy wiki for more info)
181 10 Quality values (phred33 scale, see Galaxy wiki for more) 183 10 Quality values (phred33 scale, see Galaxy wiki for more)
182 184
183 185
184 .. _consensus: http://samtools.sourceforge.net/cns0.shtml 186 .. _consensus: http://samtools.sourceforge.net/cns0.shtml
185 187 ]]></help>
186 ------ 188 <citations>
187 189 <citation type="doi">10.1093/bioinformatics/btp352</citation>
188 **Citation** 190 </citations>
189
190 For the underlying tool, please cite `Li H, Handsaker B, Wysoker A, Fennell T, Ruan J, Homer N, Marth G, Abecasis G, Durbin R; 1000 Genome Project Data Processing Subgroup. The Sequence Alignment/Map format and SAMtools. Bioinformatics. 2009 Aug 15;25(16):2078-9. &lt;http://www.ncbi.nlm.nih.gov/pubmed/19505943&gt;`_
191
192
193 </help>
194 </tool> 191 </tool>
195
196