view picard_CollectWgsMetrics.xml @ 5:2f3cdd537834 draft

planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/picard commit 6e148b31fed1b322ce720804d8525088ec6d43f9
author devteam
date Thu, 29 Oct 2015 22:23:28 -0400
parents 52fdfc45590a
children 08f69add4d06
line wrap: on
line source

<tool name="CollectWgsMetrics" id="picard_CollectWgsMetrics" version="@TOOL_VERSION@.0">
  <description>compute metrics for evaluating of whole genome sequencing experiments</description>
  <macros>
    <import>picard_macros.xml</import>
  </macros>
  <expand macro="requirements" />
  <command>
    @java_options@
    ##set up input files

    #set $reference_fasta_filename = "localref.fa"
    
    #if str( $reference_source.reference_source_selector ) == "history":
        ln -s "${reference_source.ref_file}" "${reference_fasta_filename}" &amp;&amp;
    #else:
        #set $reference_fasta_filename = str( $reference_source.ref_file.fields.path )
    #end if
    
    java -jar \$JAVA_JAR_PATH/picard.jar
    CollectWgsMetrics
    INPUT="${inputFile}"
    OUTPUT="${outFile}"
    REFERENCE_SEQUENCE="${reference_fasta_filename}"
    MINIMUM_MAPPING_QUALITY="${minimum_mapping_quality}"
    MINIMUM_BASE_QUALITY="${minimum_base_quality}"
    COVERAGE_CAP="${coverage_cap}"
    
    VALIDATION_STRINGENCY="${validation_stringency}"
    QUIET=true
    VERBOSITY=ERROR
  
  </command>
  <inputs>
    <param format="sam,bam" name="inputFile" type="data" label="Select SAM/BAM dataset or dataset collection" help="If empty, upload or import a SAM/BAM dataset"/>
    <conditional name="reference_source">
      <param name="reference_source_selector" type="select" label="Load reference genome from">
        <option value="cached">Local cache</option>
        <option value="history">History</option>
      </param>
      <when value="cached">
        <param name="ref_file" type="select" label="Using reference genome" help="REFERENCE_SEQUENCE">
          <options from_data_table="all_fasta">
          </options>
          <validator type="no_options" message="A built-in reference genome is not available for the build associated with the selected input file"/>
        </param>
      </when>
      <when value="history">
        <param name="ref_file" type="data" format="fasta" label="Use the folloing dataset as the reference sequence" help="REFERENCE_SEQUENCE; You can upload a FASTA sequence to the history and use it as reference" />
      </when>
    </conditional>
    <param name="minimum_mapping_quality" type="integer" value="20" label="Minimum mapping quality for a read to contribute coverage" help="MINIMUM_MAPPING_QUALITY; default=20"/>
    <param name="minimum_base_quality" type="integer" value="20" label="Minimum base quality for a base to contribute coverage" help="MINIMUM_BASE_QUALITY; default=20"/>
    <param name="coverage_cap" type="integer" value="250" label="Treat bases with coverage exceeding this value as if they had coverage at this value" help="COVERAGE_CAP; default=250"/>

    
    <expand macro="VS" />
    
  </inputs>
  
  <outputs>
    <data format="tabular" name="outFile" label="${tool.name} on ${on_string}: Summary data"/>
  </outputs>
  
  <tests>
    <test>
      <param name="reference_source_selector" value="history" />
      <param name="minimum_mapping_quality" value="20" />
      <param name="minimum_base_quality" value="20" />
      <param name="coverage_cap" value="250" />
      <param name="ref_file" value="picard_CollectWgsMetrics_ref.fa" />
      <param name="inputFile" value="picard_CollectWgsMetrics.bam" ftype="bam" />
      <output name="outFile" file="picard_CollectWgsMetrics_test1.tab" ftype="tabular" lines_diff="4"/>
    </test> 
  </tests>
  
  <stdio>
    <exit_code range="1:"  level="fatal"/>
  </stdio>
  
  <help>

.. class:: infomark

**Purpose**

Computes a number of metrics that are useful for evaluating coverage and performance of whole genome sequencing experiments.

@dataset_collections@

@description@

  MINIMUM_MAPPING_QUALITY=Integer
  MQ=Integer                    Minimum mapping quality for a read to contribute coverage.  Default value: 20. 

  MINIMUM_BASE_QUALITY=Integer
  Q=Integer                     Minimum base quality for a base to contribute coverage.  Default value: 20. 

  COVERAGE_CAP=Integer
  CAP=Integer                   Treat bases with coverage exceeding this value as if they had coverage at this value.  
                                Default value: 250. 

@more_info@

  </help>
</tool>