view snippy_clean_full_aln.xml @ 13:d220115f882b draft default tip

"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/snippy commit 4a4272101587c70abd11779660e77bc8718688e2"
author iuc
date Sat, 10 Jul 2021 07:46:31 +0000
parents fa016f1eea1a
children
line wrap: on
line source

<?xml version="1.0" encoding="utf-8"?>
<tool id="snippy_clean_full_aln" name="snippy-clean_full_aln" version="@WRAPPER_VERSION@+galaxy@VERSION_SUFFIX@">
    <description>
        Replace any non-standard sequence characters in snippy 'core.full.aln' file.
    </description>
    <macros>
        <import>macros.xml</import>
    </macros>
    <expand macro="requirements" />
    <command detect_errors="exit_code"><![CDATA[
        snippy-clean_full_aln
            '${full_aln}'
            #if $custom_char.custom_char_selector:
              --to '${custom_char.to_char}'
            #end if
            > '${clean_full_aln}'
    ]]></command>

    <inputs>
        <param name="full_aln" type="data" format="fasta" label="Snippy core.full.aln file" help="" />
        <conditional name="custom_char">
            <param name="custom_char_selector" type="boolean" display="radio" label="Use custom replacement character" />
            <when value="false" />
            <when value="true">
                <param name="to_char" type="text" label="Replacement character" help="Replace non-[AGTCN-] chars with this character, defaults to 'N' if none entered" >
                    <sanitizer>
                        <valid initial="string.printable">
                            <remove value="&apos;" />
                        </valid>
                        <mapping initial="none">
                            <add source="&apos;" target="&apos;&quot;&apos;&quot;&apos;" />
                        </mapping>
                    </sanitizer>
                </param>
            </when>
        </conditional>
    </inputs>
    <outputs>
        <data name="clean_full_aln" format="fasta" label="${tool.name} on ${on_string} cleaned core alignment" />
    </outputs>
    <tests>
        <test>
            <param name="full_aln" value="core.full.nonclean.aln" />
            <output name="clean_full_aln">
                <assert_contents>
                    <has_line line="GCNNCG" />
                </assert_contents>
            </output>
        </test>
        <test>
            <param name="full_aln" value="core.full.nonclean.aln" />
            <param name="custom_char_selector" value="true" />
            <param name="to_char" value="X" />
            <output name="clean_full_aln">
                <assert_contents>
                    <has_line line="GCXXCG" />
                </assert_contents>
            </output>
        </test>
    </tests>
    <help><![CDATA[
    The core.full.aln file is a FASTA formatted multiple sequence alignment file. 
    It has one sequence for the reference, and one for each sample participating 
    in the core genome calculation. Each sequence has the same length as the reference 
    sequence.

    Character 	Meaning
    ATGC 	Same as the reference
    atgc 	Different from the reference
    - 	Zero coverage in this sample or a deletion relative to the reference
    N 	Low coverage in this sample (based on --mincov)
    X 	Masked region of reference (from --mask)
    n 	Heterozygous or poor quality genotype (has GT=0/1 or QUAL < --minqual in snps.raw.vcf)
   
    You can remove all the "weird" characters and replace them with N using this tool. 
    This is useful when you need to pass it to a tree-building or recombination-removal 
    tool:

    ```
    % snippy-clean_full_aln core.full.aln > clean.full.aln
    % run_gubbins.py -p gubbins clean.full.aln
    % snp-sites -c gubbins.filtered_polymorphic_sites.fasta > clean.core.aln
    % FastTree -gtr -nt clean.core.aln > clean.core.tree
    ```
    ]]></help>
    <expand macro="citations" />
</tool>