view samtools_phase.xml @ 4:ee06ec9cf0a6 draft

planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tool_collections/samtools/samtools_phase commit de7140295cce07e1bc1697e51dab4271c8d7a8a6
author devteam
date Fri, 18 Dec 2015 19:45:25 -0500
parents c21cb56fbbbc
children 2311187710fb
line wrap: on
line source

<tool id="samtools_phase" name="Call and phase" version="2.0">
    <description>heterozygous SNPs</description>
    <macros>
    <import>macros.xml</import>
  </macros>
  <expand macro="requirements"></expand>
  <expand macro="stdio"></expand>
  <expand macro="version_command"></expand>
    <command>samtools phase -b "phase_wrapper"
        #if str($option_set.option_sets) == 'advanced':
            ${option_set.ignore_chimeras}
            -k $option_set.block_length
            -q $option_set.min_het
            -Q $option_set.min_bq
            -D $option_set.read_depth
            ${option_set.drop_ambiguous}
        #else
            -k 13 -q 37 -Q 13 -D 256
        #end if
        "$input_bam" &gt; "$phase_sets"
    </command>
    <inputs>
        <param format="bam" name="input_bam" type="data" label="Select dataset to phase"/>
        <conditional name="option_set">
            <param name="option_sets" type="select" label="Phase parameters">
                <option value="default">Use defaults</option>
                <option value="advanced">Advanced options</option>
            </param>
            <when value="default" />
            <when value="advanced">
                <param name="block_length" type="integer" value="13" label="Maximum length for local phasing" />
                <param name="min_het" type="integer" value="37" label="Minimum Phred-scaled level of detail to call a heterozygote" />
                <param name="min_bq" type="integer" value="13" label="Minimum base quality to be used in het calling" />
                <param name="read_depth" type="integer" value="256" label="Read depth" />
                <param name="ignore_chimeras" type="boolean" truevalue="-F" falsevalue="" checked="False" label="Do not attempt to fix chimeric reads" />
                <param name="drop_ambiguous" type="boolean" truevalue="-A 1" falsevalue="" checked="False" label="Drop reads with ambiguous phase" />
            </when>
        </conditional>
    </inputs>
    <outputs>
        <data format="txt" name="phase_sets" />
        <data format="bam" from_work_dir="phase_wrapper.0.bam" name="phase0" label="${tool.name} on ${on_string}: Phase-0 reads" />
        <data format="bam" from_work_dir="phase_wrapper.1.bam" name="phase1" label="${tool.name} on ${on_string}: Phase-1 reads" />
        <data format="bam" from_work_dir="phase_wrapper.chimeras.bam" name="chimera" label="${tool.name} on ${on_string}: Chimeric reads" />
    </outputs>
    <tests>
        <test>
            <param name="option_sets" value="default" /> 
            <param name="input_bam" value="samtools_phase_in_1.bam" /> 
            <output name="phase_sets" file="samtools_phase_out_1_log.txt" ftype="txt" />
            <output name="phase0" file="samtools_phase_out_1_phase0.bam" ftype="bam" />
            <output name="phase1" file="samtools_phase_out_1_phase1.bam" ftype="bam" />
            <output name="chimera" file="empty_file.bam" compare="contains" />
        </test>
        <test>
            <param name="input_bam" value="samtools_phase_in_2.bam" /> 
            <param name="option_sets" value="advanced" /> 
            <param name="option_set|block_length" value="13" />
            <param name="option_set|min_het" value="37" />
            <param name="option_set|min_bq" value="13" />
            <param name="option_set|read_depth" value="256" />
            <param name="option_set|ignore_chimeras" value="false" />
            <param name="option_set|drop_ambiguous" value="true" />
            <output name="phase_sets" file="samtools_phase_out_2_log.txt" ftype="txt" />
            <output name="phase0" file="samtools_phase_out_2_phase0.bam" ftype="bam" />
            <output name="phase1" file="samtools_phase_out_2_phase1.bam" ftype="bam" />
            <output name="chimera" file="empty_file.bam" compare="contains" />
        </test>
        <test>
            <param name="input_bam" value="samtools_phase_in_2.bam" /> 
            <param name="option_sets" value="advanced" /> 
            <param name="option_set|block_length" value="13" />
            <param name="option_set|min_het" value="37" />
            <param name="option_set|min_bq" value="13" />
            <param name="option_set|read_depth" value="256" />
            <param name="option_set|ignore_chimeras" value="true" />
            <param name="option_set|drop_ambiguous" value="false" />
            <output name="phase_sets" file="samtools_phase_out_3_log.txt" ftype="txt" />
            <output name="phase0" file="samtools_phase_out_3_phase0.bam" ftype="bam" />
            <output name="phase1" file="samtools_phase_out_3_phase1.bam" ftype="bam" />
            <output name="chimera" file="empty_file.bam" compare="contains" />
        </test>
    </tests>
    <help>
**What it does**

Call and phase heterozygous SNPs
    
------

.. list-table:: **Options**
   :widths: 5 5 40 10
   :header-rows: 1

   * - Flag
     - Type
     - Description
     - Default
   * - -k
     - INT
     - Block length
     - 13
   * - -b
     - STR
     - Prefix of BAM file output
     - *null*
   * - -q
     - INT
     - Minimum het phred-LOD
     - 37
   * - -Q
     - INT
     - Min base quality in het calling
     - 13
   * - -D
     - INT
     - Max read depth
     - 256
   * - -D
     - BOOLEAN
     - Do not attempt to fix chimeras
     - *off*
   * - -A
     - BOOLEAN
     - Drop reads with ambiguous phase
     - *off*

    </help>
    <expand macro="citations"></expand>
</tool>