view mafft-add.xml @ 14:6f28e90db932 draft

planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/mafft commit 1570f3a28232b4b88385cdfbb68f79d80ff1dabb
author bgruening
date Tue, 31 Oct 2023 15:48:53 +0000
parents aaefa93c2dd2
children bf28a8cff401
line wrap: on
line source

<?xml version="1.0" encoding="UTF-8"?>
<tool id="rbc_mafft_add" name="MAFFT add" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="@PROFILE@">
  <description>Align a sequence,alignment or fragments to an existing alignment.</description>
  <macros>
    <import>macros.xml</import>
  </macros>
  <expand macro="biotools"/>
  <expand macro="requirements"/>
  <stdio>
    <exit_code range="1:" level="fatal" description="Error occurred. Please check Tool Standard Error" />
    <exit_code range=":-1" level="fatal" description="Error occurred. Please check Tool Standard Error" />
  </stdio>
  <version_command>    <![CDATA[
    mafft --version
    ]]>
  </version_command>
  <command>
    <![CDATA[
      mafft
      #if $sequences.sequenceType == 'singleseq'
        $sequences.preservegap  '$inputSequences'
      #elif $sequences.sequenceType == 'frags'
        --addfragments '$inputSequences'
      #elif $sequences.sequenceType == 'group'
        --addprofile '$inputSequences'
      #end if
      $keeplength $map $reorder
      '$inputAlignment'
      > '$outputAlignment'
      #if $map == '--mapout'
        && mv '${inputSequences}.map' '$outputmap'
      #end if
    ]]>
  </command>
  <inputs>
    <param name="inputSequences" type="data" format="fasta" label="Sequences to add to the alignment" help="Amino acid or nucleotide sequences in FASTA format."/>
    <param name="inputAlignment" type="data" format="fasta" label="Alignment" help="Amino acid or nucleotide sequences in aligned FASTA format."/>
    <conditional name="sequences">
      <param name="sequenceType" type="select" label="What do you want to add to the alignment" >
        <option value="singleseq">A single sequence</option>
        <option value="frags" selected="true">Fragments</option>
        <option value="group">An alignment</option>
      </param>
      <when value='singleseq'>
        <param name="preservegap" type="select" label="Preserve the original alignment" help="Keep the given alignment unchanged (--add .)If not, the aligned letters in the seed alignment are preserved but gaps are not necessarily preserved (--seed)">
          <option value="--add" selected="true" >Yes</option>
          <option value="--seed">no</option>
        </param>
      </when>
      <when value='frags'/>
      <when value='group'/>
    </conditional>
    <param name="keeplength" type="boolean" truevalue="--keeplength" falsevalue="" checked="True" label="Keep alignment length" help="The alignment length is unchanged.  Insertions at the additional sequences are deleted" />
    <param name="map" type="boolean" truevalue="--mapout" falsevalue="" checked="False" label="Output a correspondance table of positions (--mapout)" help="Output a correspondence table of positions, sequence.map, between before and after the calculation.  The --mapout option automatically turns on the --keeplength option, to keep the numbering of sites in the reference alignment" />
    <param name="reorder" type="boolean" truevalue="" falsevalue="--reorder" checked="True" label="Preserve the original order of sequences (--reorder)"  />
  </inputs>
  <outputs>
    <data format="fasta" name="outputAlignment" label="${tool.name} on ${on_string} : New alignment"/>
    <data name="outputmap" format="tabular" label="${tool.name} on ${on_string} : Correspondance of positions ">
      <filter>map == True</filter>
    </data>
  </outputs>
  <tests>
    <test expect_num_outputs="1" >
      <param name="inputSequences" value="add_seq.fa"/>
      <param name="inputAlignment" value="mafft_fftns_result.aln"/>
      <param name="sequenceType" value="singleseq"/>
      <param name="preservegap" value="--add"/>
      <param name="keeplength" value="--keeplength"/>
      <param name="map" value=""/>
      <output name="outputAlignment" ftype="fasta" file="mafft_add_result.aln"/>
    </test>
  </tests>
  <help>
    <![CDATA[
Add one of more sequences to an existing alignment. The new sequence(s) can be complete, fragments, or another alignement.

- Sequences in new_sequences are ungapped and then aligned to existing_alignment.
- new_sequences is a single multi-FASTA format file.
- existing_alignment is a single multi-FASTA format file.
- Gaps in existing_alignment are preserved by default (--add), but it can be deactivated (--seed). In that case the aligned letters in the seed alignment are preserved but gaps are not necessarily preserved.
- The alignment length may be conserved if the --keeplength option is given. The alignment length is unchanged.  Insertions at the new sequences are deleted.
- --mapout options output a correspondence table of positions, new_sequences.map, between before and after the calculation.  The --mapout option automatically turns on the --keeplength option, to keep the numbering of sites in the reference alignment.
- Omit --reorder to preserve the original sequence order.

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