Mercurial > repos > iuc > samtools_depth
diff samtools_depth.xml @ 0:090651229eba draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tool_collections/samtools/samtools_depth commit b75040a9832972a60a964bc5a35da029d2bcf86c
author | iuc |
---|---|
date | Sun, 14 Oct 2018 19:14:57 -0400 |
parents | |
children | 44de678a44c4 |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/samtools_depth.xml Sun Oct 14 19:14:57 2018 -0400 @@ -0,0 +1,114 @@ +<tool id="samtools_depth" name="Samtools depth" version="1.8"> + <description>compute the depth at each position or region</description> + <macros> + <import>macros.xml</import> + </macros> + <expand macro="requirements"/> + <expand macro="stdio"/> + <expand macro="version_command"/> + <command><![CDATA[ +## create symlinks to bams and index files (0,..., n-1 + 0.[bai|crai],...,n-1.[bai|crai] ) +@PREPARE_IDX_MULTIPLE@ + +samtools depth +$all +#if $cond_region.select_region == 'bed': + -b '$cond_region.input_bed' +#else if $cond_region.select_region == 'text': + -r $cond_region.region +#end if +#if str($minlength) != '': + -l $minlength +#end if +#if str($maxdepth) != '': + -m $maxdepth +#end if +#if str($basequality) != '': + -q $basequality +#end if +#if str($mapquality) != '': + -Q $mapquality +#end if +#for $i in range(len( $input_bams )): + ${i} +#end for +> '${output}' + ]]></command> + <inputs> + <param name="input_bams" type="data" format="bam" multiple="true" label="BAM file(s)" /> + <conditional name="cond_region"> + <param name="select_region" type="select" label="Filter by regions"> + <option value="no" selected="True">No</option> + <option value="text">Manualy specify a region</option> + <option value="bed">Regions from BED file</option> + </param> + <when value="no"/> + <when value="text"> + <param name="region" type="text" optional="false" argument="-r" label="Only report depth in a specified region" help="Format is CHROMOSOME:FROM-TO"/> + </when> + <when value="bed"> + <param name="input_bed" type="data" format="bed" argument="-b" label="Genomic intervals (in BED format)" help="Compute depth at list of positions or regions in specified BED FILE." /> + </when> + </conditional> + + <param name="all" type="select" argument="-a/-aa" label="Output all positions" help="Note that if the all option (-a) is used in conjunction with a BED file it may sometimes operate as if -aa was specified if the reference sequence has coverage outside of the region specified in the BED file."> + <option value="" selected="True">Default</option> + <option value="-a">Output all positions (including those with zero depth) (-a)</option> + <option value="-aa">Output absolutely all positions, including unused reference sequences. (-aa)</option> + </param> + <param name="minlength" type="integer" argument="-l" min="0" optional="true" label="Ignore reads shorter than" /> + <param name="maxdepth" type="integer" argument="-m" min="0" optional="true" label="Limits the maximum number of considered alignments starting at any sequence position to INT. Note that, the reported depths values might be larger than INT. If 0, depth is set to the maximum integer value, effectively removing any depth limit. (default = 8000)" /> + + <param name="basequality" type="integer" argument="-q" min="0" optional="true" label="Only count reads with base quality greater than" /> + <param name="mapquality" type="integer" argument="-Q" min="0" optional="true" label="Only count reads with mapping quality greater than" /> + </inputs> + <outputs> + <data name="output" format="tabular" label="${tool.name} on ${on_string}" /> + </outputs> + <tests> + <test> + <conditional name="cond_region"> + <param name="select_region" value="bed"/> + <param name="input_bed" value="eboVir3.1.bed" ftype="bed" /> + </conditional> + <param name="input_bams" value="eboVir3.bam" ftype="bam" /> + <output name="output" file="samtools_depth_out1.tab" /> + </test> + <test> + <conditional name="cond_region"> + <param name="select_region" value="text"/> + <param name="region" value="eboVir3:500-1500" /> + </conditional> + <param name="input_bams" value="eboVir3.bam" ftype="bam" /> + <output name="output" file="samtools_depth_out2.tab" /> + </test> + <test> + <param name="input_bams" value="eboVir3.bam,eboVir3.2.bam" ftype="bam" /> + <param name="all" value="-a"/> + <output name="output" file="samtools_depth_out3.tab" /> + </test> + <test> + <param name="input_bams" value="eboVir3.bam,eboVir3.2.bam" ftype="bam" /> + <param name="minlength" value="10" /> + <!-- Odd thing: I did not expect values > 4 in the output, but there are ... ? + see https://github.com/samtools/samtools/issues/889 --> + <param name="maxdepth" value="4" /> + <param name="basequality" value="11" /> + <param name="mapquality" value="12" /> + <output name="output" file="samtools_depth_out4.tab" /> + </test> + </tests> + <help> +**What it does** + +Computes the depth at each position or region using the ``samtools depth`` command. + +The output is a tabular file, with one line for each base of each reference +with any coverage (bases with no coverage may not appear). + +The first column is the reference name, the second column is the reference +position, and then there is one column for each SAM/BAM file giving the +coverage depth at that position. + </help> + <expand macro="citations"/> +</tool>