view mothur/tools/mothur/remove.seqs.xml @ 2:e990ac8a0f58

Migrated tool version 1.19.0 from old tool shed archive to new tool shed repository
author jjohnson
date Tue, 07 Jun 2011 17:39:06 -0400
parents fcc0778f6987
children 5265aa9067e0
line wrap: on
line source

<tool id="mothur_remove_seqs" name="Remove.seqs" version="1.19.0">
 <description>Remove sequences by name</description>
 <command interpreter="python">
  mothur_wrapper.py 
  #import re, os.path
  #set results = ["'^mothur.\S+\.logfile$:'" + $logfile.__str__]
  ## adds .pick before the last extension to the input file (except align.report)
  --cmd='remove.seqs'
  --outputdir='$logfile.extra_files_path'
  --accnos=$accnos
  #if $fasta_in.__str__ != "None" and len($fasta_in.__str__) > 0:
   --fasta=$fasta_in
   #set results = $results + ["'" + $re.sub(r'(^.*)\.(.*?)',r'\1.pick.\2',$os.path.basename($fasta_in.__str__)) + ":'" + $fasta_out.__str__]
  #end if
  #if $qfile_in.__str__ != "None" and len($qfile_in.__str__) > 0:
   --qfile=$qfile_in
   #set results = $results + ["'" + $re.sub(r'(^.*)\.(.*?)',r'\1.pick.\2',$os.path.basename($qfile_in.__str__)) + ":'" + $qfile_out.__str__]
  #end if
  #if $name_in.__str__ != "None" and len($name_in.__str__) > 0:
   --name=$name_in
   #set results = $results + ["'" + $re.sub(r'(^.*)\.(.*?)',r'\1.pick.\2',$os.path.basename($name_in.__str__)) + ":'" + $name_out.__str__]
   $dups
  #end if
  #if $group_in.__str__ != "None" and len($group_in.__str__) > 0:
   --group=$group_in
   #set results = $results + ["'" + $re.sub(r'(^.*)\.(.*?)',r'\1.pick.\2',$os.path.basename($group_in.__str__)) + ":'" + $group_out.__str__]
  #end if
  #if $alignreport_in.__str__ != "None" and len($alignreport_in.__str__) > 0:
   --alignreport=$alignreport_in
   #set results = $results + ["'" + $re.sub(r'(^.*)\.(.*?)$',r'\1.pick.align.report',$os.path.basename($alignreport_in.__str__)) + ":'" + $alignreport_out.__str__]
  #end if
  #if $list_in.__str__ != "None" and len($list_in.__str__) > 0:
   --list=$list_in
   #set results = $results + ["'" + $re.sub(r'(^.*)\.(.*?)',r'\1.pick.\2',$os.path.basename($list_in.__str__)) + ":'" + $list_out.__str__]
  #end if
  #if $taxonomy_in.__str__ != "None" and len($taxonomy_in.__str__) > 0:
   --taxonomy=$taxonomy_in
   #set results = $results + ["'" + $re.sub(r'(^.*)\.(.*?)',r'\1.pick.\2',$os.path.basename($taxonomy_in.__str__)) + ":'" + $taxonomy_out.__str__]
  #end if
  --result=#echo ','.join($results)
 </command>
 <inputs>
  <param name="accnos" type="data" format="accnos" label="accnos - Accession Names"/>
  <param name="fasta_in" type="data" format="fasta,align" optional="true" label="fasta - Fasta Sequences"/>
  <param name="qfile_in" type="data" format="qual,qual454" optional="true" label="qfile - Fasta Quality"/>
  <param name="name_in" type="data" format="names" optional="true" label="name - Sequences Name reference"/>
  <param name="group_in" type="data" format="groups" optional="true" label="group - Sequences Groups"/>
  <param name="alignreport_in" type="data" format="align.report" optional="true" label="alignreport - Align Report"/>
  <param name="list_in" type="data" format="list" optional="true" label="list - OTU List"/>
  <param name="taxonomy_in" type="data" format="seq.taxonomy" optional="true" label="taxonomy - Taxonomy"/>
  <param name="dups" type="boolean" truevalue="" falsevalue="--dups=false" checked="true" label="dups - Apply to duplicates"/>
 </inputs>
 <outputs>
  <data format="html" name="logfile" label="${tool.name} on ${on_string}: logfile" />
  <!-- format should be set to match input -->
  <!-- There should be a  format_source   attribute
  <data format_source="fasta_in" metadata_source="fasta_in" name="fasta_out" label="${tool.name} on ${on_string}: pick.${fasta_in.datatype.file_ext}">
   <filter>fasta_in != None</filter>
  </data>
  -->
  <data format="fasta" metadata_source="fasta_in" name="fasta_out" label="${tool.name} on ${on_string}: pick.${fasta_in.datatype.file_ext}">
   <filter>fasta_in != None</filter>
   <change_format>
     <when input="${fasta_in.datatype.file_ext}" value="align" format="align" />
   </change_format>
  </data>
  <!-- format should be set to match input -->
  <data format="qual" name="qfile_out" label="${tool.name} on ${on_string}: pick.qfile">
   <filter>qfile_in != None</filter>
   <change_format>
     <when input="${qfile_in.datatype.file_ext}" value="qual454" format="qual454" />
   </change_format>
  </data>
  <data format="names" name="name_out" label="${tool.name} on ${on_string}: pick.names">
   <filter>name_in != None</filter>
  </data>
  <data format="groups" name="group_out" label="${tool.name} on ${on_string}: pick.groups">
   <filter>group_in != None</filter>
  </data>
  <data format="align.report" name="alignreport_out" label="${tool.name} on ${on_string}: pick.align.report">
   <filter>alignreport_in != None</filter>
  </data>
  <data format="list" name="list_out" label="${tool.name} on ${on_string}: pick.list">
   <filter>list_in != None</filter>
  </data>
  <data format="seq.taxonomy" name="taxonomy_out" label="${tool.name} on ${on_string}: pick.taxonomy">
   <filter>taxonomy_in != None</filter>
  </data>
 </outputs>
 <requirements>
  <requirement type="binary">mothur</requirement>
 </requirements>
 <tests>
 </tests>
 <help>
**Mothur Overview**

Mothur_, initiated by Dr. Patrick Schloss and his software development team
in the Department of Microbiology and Immunology at The University of Michigan,
provides bioinformatics for the microbial ecology community.

.. _Mothur: http://www.mothur.org/wiki/Main_Page

**Command Documenation**

The remove.seqs_ command takes a list of sequence names and either a fasta, name_, group_, list_, align.report_ or taxonomy_ file to generate a new file that does not contain the sequences in the list. This command may be used in conjunction with the list.seqs_ command to help screen a sequence collection.

.. _name: http://www.mothur.org/wiki/Name_file
.. _group: http://www.mothur.org/wiki/Group_file
.. _list: http://www.mothur.org/wiki/List_file
.. _align.report: http://www.mothur.org/wiki/Align.seqs
.. _taxonomy: http://www.mothur.org/wiki/Taxonomy_outline
.. _list.seqs: http://www.mothur.org/wiki/list.seqs
.. _remove.seqs: http://www.mothur.org/wiki/Remove.seqs

 </help>
</tool>