Mercurial > repos > iuc > bedtools
view genomeCoverageBed.xml @ 32:4f7a5ccd2ae9 draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit fc3616bd1463afef9681cd7c431ac29f79e37e74
author | iuc |
---|---|
date | Tue, 11 Dec 2018 14:01:26 -0500 |
parents | 95a3b2c25bd1 |
children | dde39ba9c031 |
line wrap: on
line source
<tool id="bedtools_genomecoveragebed" name="bedtools Genome Coverage" version="@WRAPPER_VERSION@"> <description>compute the coverage over an entire genome</description> <macros> <import>macros.xml</import> </macros> <expand macro="requirements" /> <expand macro="stdio" /> <command> <![CDATA[ bedtools genomecov @GENOME_FILE_COVERAGE@ $split $strand #if str($report.report_select) == "bg": #if $report.zero_regions: $report.zero_regions #else: -bg #end if #if str($report.scale): -scale $report.scale #end if #else: #if str($report.max): -max $report.max #end if #end if $d $dz $five $three > '$output' ]]> </command> <inputs> <conditional name="input_type"> <param name="input_type_select" type="select" label="Input type"> <option value="bed">@STD_BEDTOOLS_INPUT_LABEL@</option> <option value="bam">BAM</option> </param> <when value="bed"> <param format="@STD_BEDTOOLS_INPUTS@" name="input" type="data" label="@STD_BEDTOOLS_INPUT_LABEL@ file" /> <expand macro="input_conditional_genome_file" /> </when> <when value="bam"> <param format="bam" name="input" type="data" label="BAM file" /> </when> </conditional> <conditional name="report"> <param name="report_select" type="select" label="Output type"> <option value="bg" selected="true">BedGraph coverage file</option> <option value="hist">Data suiteable for Histogram</option> </param> <when value="bg"> <param name="zero_regions" type="boolean" checked="False" truevalue="-bga" falsevalue="" label="Report regions with zero coverage" help="If set, regions without any coverage will also be reported. (-bga)" /> <param name="scale" type="float" value="1.0" label="Scale the coverage by a constant factor" help="Each bedGraph coverage value is multiplied by this factor before being reported. Useful for normalizing coverage by, e.g., reads per million (RPM). (-scale)" /> </when> <when value="hist"> <param name="max" type="integer" label="Specify max depth" value="0" help="Combine all positions with a depth >= max into a single bin in the histogram. (-max)" /> </when> </conditional> <expand macro="split" /> <param name="strand" type="select" label="Calculate coverage based on" help="(-strand)"> <option value="">both strands combined</option> <option value="-strand +">positive strand only</option> <option value="-strand -">negative strand only</option> </param> <param name="d" type="boolean" checked="False" truevalue="-d" falsevalue="" label="Report the depth at each genome position with 1-based coordinates" help="(-d)" /> <param name="dz" type="boolean" checked="False" truevalue="-dz" falsevalue="" label="Report the depth at each genome position with 0-based coordinatess" help="(-dz)" /> <param name="five" type="boolean" checked="False" truevalue="-5" falsevalue="" label="Calculate coverage of 5’ positions" help="Instead of entire interval. (-5)" /> <param name="three" type="boolean" checked="False" truevalue="-3" falsevalue="" label="Calculate coverage of 3’ positions" help="Instead of entire interval. (-3)" /> </inputs> <outputs> <data format="bedgraph" name="output"> <change_format> <when input="report.report_select" value="hist" format="tabular" /> </change_format> </data> </outputs> <tests> <test> <param name="input_type_select" value="bed" /> <param name="input" value="genomeCoverageBed1.bed" ftype="bed" /> <param name="genome_file_opts_selector" value="hist" /> <param name="genome" value="genomeCoverageBed1.len" ftype="tabular" /> <param name="report_select" value="hist" /> <output name="output" file="genomeCoverageBed_result1.bed" ftype="tabular" /> </test> </tests> <help> <![CDATA[ **What it does** This tool calculates the genome-wide coverage of intervals defined in a BAM or BED file and reports them in BedGraph format. .. image:: $PATH_TO_IMAGES/genomecov-glyph.png .. class:: warningmark The input BED or BAM file must be sorted by chromosome name (but doesn't necessarily have to be sorted by start position). ----- **Example 1** Input (BED format)- Overlapping, un-sorted intervals:: chr1 140 176 chr1 100 130 chr1 120 147 Output (BedGraph format)- Sorted, non-overlapping intervals, with coverage value on the 4th column:: chr1 100 120 1 chr1 120 130 2 chr1 130 140 1 chr1 140 147 2 chr1 147 176 1 ----- **Example 2 - with ZERO-Regions selected (assuming hg19)** Input (BED format)- Overlapping, un-sorted intervals:: chr1 140 176 chr1 100 130 chr1 120 147 BedGraph output will contain five columns: * 1. Chromosome name (or 'genome' for whole-genome coverage) * 2. Coverage depth * 3. The number of bases on chromosome (or genome) with depth equal to column 2. * 4. The size of chromosome (or entire genome) in base pairs * 5. The fraction of bases on chromosome (or entire genome) with depth equal to column 2. **Example Output**: chr2L 0 1379895 23011544 0.0599653 chr2L 1 837250 23011544 0.0363839 chr2L 2 904442 23011544 0.0393038 chr2L 3 913723 23011544 0.0397072 chr2L 4 952166 23011544 0.0413778 chr2L 5 967763 23011544 0.0420555 chr2L 6 986331 23011544 0.0428624 chr2L 7 998244 23011544 0.0433801 chr2L 8 995791 23011544 0.0432735 chr2L 9 996398 23011544 0.0432999 @REFERENCES@ ]]> </help> <expand macro="citations" /> </tool>