view shear_assemble.xml @ 2:b84716da5595

Update to SHEAR v0.2.9
author Jim Johnson <jj@umn.edu>
date Sun, 27 Apr 2014 19:57:03 -0500
parents 3cbbffb3ae47
children 7506693aff3b
line wrap: on
line source

<tool id="shear_assemble" name="SHEAR-Assemble" version="0.0.9">
  <description>create a personal genome from sdi</description>
  <requirements>
    <requirement type="package" version="0.2.9">shear</requirement>
  </requirements>
  <!--
  <version_command></version_command>
  -->
  <command interpreter="python">
    shear_wrapper.py -j \$SHEAR_JAR_PATH/SHEAR.jar --command assemble 
    -p $prefix
    -s $sdi_file
    #if $genomeSource.refGenomeSource == 'indexed':
      -f $genomeSource.ref_fastas.fields.path
    #else:
      -f $genomeSource.ref_fasta
    #end if
    -o $output_fasta
  </command>
  <inputs>
    <param name="prefix" type="text" value="shear_assemble" label="Prefix for all generated files">
      <validator type="regex" message="Prefix should start with a letter and contain only letter, digit, and '_' or '-' characters">[a-zA-Z0-9][_a-zA-Z0-9-]*</validator>
    </param>
    <param name="sdi_file" type="data" format="shear.sdi" label="SDI file produced by SHEAR's 'sv' command containing the SVs to use to create the new genomic sequence."/> 
    <!-- reference data -->
    <conditional name="genomeSource">
      <param name="refGenomeSource" type="select" label="Will you select a reference genome from your history or use a cached file?">
        <option value="indexed">Use a cached reference genome</option>
        <option value="history">Use one from the history</option>
      </param>
      <when value="indexed">
        <param name="ref_fastas" type="select" label="Select a reference genome">
          <options from_data_table="all_fasta">
            <filter type="sort_by" column="2" />
            <validator type="no_options" message="No reference fasta files are available" />
          </options>
        </param>
      </when>
      <when value="history">
        <param name="ref_fasta" type="data" format="fasta" metadata_name="dbkey" label="Select a reference from history" />
      </when>
    </conditional>
  </inputs>
  <stdio>
    <exit_code range="1:" level="fatal" description="Error" />
  </stdio>
  <outputs>
    <data format="fasta" name="output_fasta" label="${tool.name} on ${on_string}: ${prefix}.fa"  />
  </outputs>
  <tests>
    <test>
      <param name="prefix" value="shear_assembly" />
      <param name="sdi_file" value="shear_sv.sdi" ftype="shear.sdi" />
      <param name="refGenomeSource" value="history"/>
      <param name="ref_fasta" value="syn.fa" ftype="fasta" />
      <output name="output_fasta"  file="simulated-data.fa"/>
    </test>
  </tests>
  <help>
SHEAR-Assemble takes a reference genome and a *.sdi file from SHEAR-SV to create a new personal genome.

Please cite the following article:

Landman SR, Hwang TH, Silverstein KAT, Li Y, Dehm SM, Steinbach M, and Kumar V. SHEAR: sample heterogeneity estimation and assembly by reference. BMC Genomics 2014, 15:84.

  </help>
</tool>