view screen.xml @ 0:c392c4007d5e

Imported from capsule None
author jjohnson
date Tue, 14 Oct 2014 10:07:00 -0400
parents
children
line wrap: on
line source

<tool name="Screen Motif" id="motif_screen" version="0.1.0">
  <description>Given a motif, find all regions that match the motif</description>
  <macros>
    <import>tool_macros.xml</import>
  </macros>
  <!-- cistrome numpy -->
  <expand macro="requirements" />
  <command>
MotifScan.py
#include source=$ref_genome_seq_opts#
-b $output_bed  -f $output_fa
#if $motifs.motifSrc == 'raw':
-p $user_db_file $bfile $bfile.metadata.dbkey ignore_this 
#elif $motifs.motifSrc == 'pssm':
-p $motifs.pssm_file $bfile $bfile.metadata.dbkey ignore_this
#elif $motifs.motifSrc == 'db':
-m $motifs.db  $bfile $bfile.metadata.dbkey $motifs.motif_id
#elif $motifs.motifSrc == 'userdb':
-n $motifs.usr_db  $bfile $bfile.metadata.dbkey $motifs.motif_id
#end if
  </command>
  <inputs>
    <param format="bed" name="bfile" type="data" label="BED file(100,000 lines max)">
      <validator type="unspecified_build" />
    </param>
    <expand macro="refGenomeSourceConditional"/>
    <conditional name="motifs">
      <param name="motifSrc" type="select" label="which motif database?">
          <option value="db">builtin motif database</option>
          <option value="userdb">motif database from your history</option>
          <option value="pssm">pssm file from your history</option>
          <option value="raw">pssm enterd as text</option>
      </param>
      <when value="pssm">
        <param format="text" name="pssm_file" type="data" label="PSSM file"/>
      </when>
      <when value="userdb">
        <param format="xml" name="usr_db" type="data" label="Motif XML file" optional="true"/>
        <param name="motif_id" type="text" label="Motif Id" help="from Seqpos result or from our motif collection /Cistrome/Cistrome.xml"/>
      </when>
      <when value="db">
        <param name="motif_id" type="text" label="Motif Id" help="from Seqpos result or from our motif collection at http://cistrome.dfci.harvard.edu/~jian/motif_collection/databases/Cistrome/Cistrome.xml"/>
        <param name="db" type="select" label="which motif database?">
          <option value="pbm.xml">pbm</option>
          <option value="y1h.xml">y1h</option>
          <option value="transfac.xml">transfac</option>
          <option value="hpdi.xml">hpdi</option>
          <option value="jaspar.xml">jaspar</option>
        </param>
      </when>
      <when value="raw">
     <param name="file_data" type="text" size="40,40" label="PSSM Raw Text (e.g. [[0.1, 0.5, 0.2, 0.2], ...])" 
            help="Tip: Zero number is not allowed (use 0.001 instead.), also 4 numbers in each part should add up to 1, "/>
      </when>
    </conditional>
  </inputs>
  <outputs>
     <data format="bed" name="output_bed" label="Motif scan output on ${bfile.name}"/>
     <data format="fasta" name="output_fa" label="Motif sequences for ${bfile.name}"/>
  </outputs>
  <configfiles>
    <configfile name="user_db_file">
#if $motifs.motifSrc == 'raw':
echo $motifs.file_data
#end if
    </configfile>
  </configfiles>
  <tests>
     <test name="denovo_foo_8">
        <param name="bfile" value="runx3_small.bed" ftype="bed" />
        <param name="gv" value="mm8" />
        <param name="motif_id" value="denovo2" />
        <param name="db" value="None" />
        <param name="usr_db" value="denovo_foo.xml" ftype="xml"/>
        <param name="pssm_file" />
        <param name="file_data" value="" />
        <output name="output1" file="motif/motifscan/outputs/denovo_foo_8.bed"/>
        <output name="output2" file="motif/motifscan/outputs/denovo_foo_8.fsa"/>
     </test>
     <test name="pssm_SW0003">
        <param name="bfile" value="runx3_small.bed" ftype="bed" />
        <param name="gv" value="mm8" />
        <param name="motif_id" value="" />
        <param name="db" value="None" />
        <param name="usr_db" />
        <param name="pssm_file" value="pssm_SW0003.txt" />
        <param name="file_data" value="" />
        <output name="output1" file="motif/motifscan/outputs/pssm_SW0003.bed"/>
        <output name="output2" file="motif/motifscan/outputs/pssm_SW0003.fsa"/>
     </test>
     <test name="y1h_SW0056">
        <param name="bfile" value="runx3_small.bed" ftype="bed" />
        <param name="gv" value="mm8" />
        <param name="motif_id" value="SW0056" />
        <param name="db" value="y1h.xml" />
        <param name="usr_db" />
        <param name="pssm_file" />
        <param name="file_data" value="" />
        <output name="output1" file="motif/motifscan/outputs/y1h_SW0056.bed"/>
        <output name="output2" file="motif/motifscan/outputs/y1h_SW0056.fsa"/>
     </test>
  </tests>
  <help>
Given a motif, this tool will find all regions that match the
motif. This tool is made by Cliff Meyer and Len Taing.

.. class:: infomark

**TIP:** Please check the result from Seqpos tool to understand the
parameters of this tool, such as Motif id, xml file, PSSM

.. class:: warningmark

**NEED IMPROVEMENT**

-----

**4 ways to specify the input**

- **Method 1:** You can specify a motif in our motif database by the
  motif id such as MM00481 for AR motif in TRANSFAC. This way, you
  need to provide id in **Motif id**, and choose a "motif database"
  from PBM, TRANSFAC or Y1H.
- **Method 2:** You can specify a motif with Seqpos result by the
  motif id such as MM00481_observed for observed AR motif. This way,
  you need to provide id in **Motif id**, and choose the Seqpos output
  xml file in the drop-down menu of **Motif XML file**.
- **Method 3:** You can upload a PSSM file containing a motif matrix
  to the history, and choose it from drag-down menu of **PSSM file**.
- **Method 4:** You can paste a PSSM raw text string to **PSSM Raw
  Text** to scan. An example for this string can be seen in Seqpos
  HTML result by selecting a motif and click the *show pssm in a new
  window* button

**Other parameters**

- **BED file** defines the regions you want to scan the motif on.
- **Genome Asssembly version** is the UCSC database version. The tool
  use this information to extract the DNA sequences in the regions of
  **BED file**.

.. class:: infomark

**TIP:** To browse the known motif databases, click here_  
link to: http://cistrome.org/~jian/motif_collection/databases/Cistrome/Cistrome.xml

.. _here: http://cistrome.org/~jian/motif_collection/databases/Cistrome/Cistrome.xml

-----

**Output**

- **BED output** contains the regions with the motif.
- **Fasta output** contains the DNA sequences of motif.


  </help>

</tool>