view nanopolish_variants.xml @ 5:ee4a11ebe451 draft

planemo upload for repository https://github.com/jvolkening/galaxy-tools/tree/master/tools/nanopolish commit 1da5a3f152e115430b04ab532541a220a8e0adba
author jdv
date Fri, 01 Dec 2017 22:13:14 -0500
parents bdd6c1ab07c5
children 36cc4ae4160e
line wrap: on
line source

<tool id="nanopolish_variants" name="Nanopolish::variants" version="0.7.2">

    <description>Re-call consensus and variants from raw signal</description>

    <!-- ***************************************************************** -->
   
    <!--
    <requirements>
        <requirement type="package" version="0.7.2">nanopolish</requirement>
    </requirements>
    -->

    <!-- ***************************************************************** -->

    <version_command>nanopolish --version | perl -wnE'print "$1\n" for /^nanopolish version (.+)$/mg'</version_command>

    <!-- ***************************************************************** -->

    <command detect_errors="aggressive">
    <![CDATA[

    ln -s $input_bam 'input.bam'  &&
    ln -s $input_bam.metadata.bam_index input.bai &&

    perl $__tool_directory__/nanopolish_variants.pl variants

        --reads     $input_reads
        --bam       input.bam
        --genome    $input_ref
        --consensus $out_consensus
        --outfile   $out_variants
        --threads \${GALAXY_SLOTS:-1}
        --max-rounds $max_rounds
        --max-haplotypes $max_haplotypes
        --min-candidate-depth $min_candidate_depth
        --min-candidate-frequency $min_candidate_frequency
        --fast5 $input_fast5
        $fix_homopolymers
        $calculate_all_support

    ]]>
    </command>

    <!-- ***************************************************************** -->

    <inputs>

        <param name="input_reads" type="data" format="fasta" label="Input reads (FASTA)" />
        <param name="input_fast5" type="data" format="fast5.tar" label="Input reads (FAST5)" />
        <param name="input_bam"   type="data" format="bam"   label="Alignment" />
        <param name="input_ref"   type="data" format="fasta" label="Reference" />
        <param name="min_candidate_frequency" type="float" value="0.2" size="5" label="Minimum candidate frequency" />
        <param name="min_candidate_depth" type="integer" min="1" value="20" size="5" label="Minimum candidate depth" />
        <param name="max_haplotypes" type="integer" min="0" value="1000" size="5" label="Maximum haplotype combinations" />
        <param name="max_rounds" type="integer" min="0" value="50" size="5" label="Maximum iterations" />
        <param name="fix_homopolymers" type="boolean" checked="false" truevalue="--fix-homopolymers" falsevalue="" label="Fix homopolymers" />
        <param name="calculate_all_support" type="boolean" checked="false" truevalue="--calculate-all-support" falsevalue="" label="Calculate support for all four bases" /> 
    </inputs>

    <!-- ***************************************************************** -->

    <outputs>

        <data name="out_variants" format="vcf" label="${tool.name} on ${on_string} (variants)" />
        <data name="out_consensus" format="fasta" label="${tool.name} on ${on_string} (consensus)" />

    </outputs>

    <!-- ***************************************************************** -->

    <tests>
        <test>
            <param name="input_reads" value="variants.reads.fa" ftype="fasta" />
            <param name="input_fast5" value="variants.in.fast5.tar.bz2" ftype="fast5.tar.bz2" />
            <param name="input_bam"   value="variants.bam" ftype="bam" />
            <param name="input_ref"   value="variants.ref.fa" ftype="fasta" />
            <param name="fix_homopolymers" value="True"/>
            <output name="out_consensus" file="variants.out.fa" compare="diff" />
        </test>
    </tests>

    <!-- ***************************************************************** -->

    <help>
    <![CDATA[

**Description**

Nanopolish is a software package for signal-level analysis of Oxford Nanopore
sequencing data. Nanopolish can calculate an improved consensus sequence for a
draft genome assembly, detect base modifications, call SNPs and indels with
respect to a reference genome and more.

The Galaxy wrapper has modified nanopolish to take a gzip tarball of FAST5 reads
as input, such as can be produced by `poretools combine`, and always outputs a
single FASTQ file.

This is the `variants` module.

    ]]>
    </help>

    <!-- ***************************************************************** -->
    
    <citations>
    </citations>

</tool>