view PDAUG_Peptide_CD_Spectral_Analysis/PDAUG_Peptide_CD_Spectral_Analysis.xml @ 6:370b68568ba2 draft

"planemo upload for repository https://github.com/jaidevjoshi83/pdaug commit e8c8198105af7eab636fb2405e5ff335539ca14b"
author jay
date Sun, 31 Jan 2021 02:46:28 +0000
parents 9bbad349f44c
children
line wrap: on
line source

<tool id="pdaug_peptide_cd_spectral_analysis" name="PDAUG Peptide CD Spectral Analysis" version="0.1.0" python_template_version="3.5">

  <description>Circular dichroism data analysis</description>

    <requirements>
      <requirement version="0.24.2" type="package" >pandas </requirement>
      <requirement version="4.2.1" type="package" >modlamp </requirement>
    </requirements>
    <command detect_errors="exit_code"><![CDATA[

        mkdir temp

        #for $i, $inp in enumerate($input1):
            && ln -s '$inp' 'temp/${i}.csv'
        #end for


        &&

        python $__tool_directory__/PDAUG_Peptide_CD_Spectral_Analysis.py  '$SelMethods.Methods' 

            #if $SelMethods.Methods == 'calc_ellipticity'
               -T '$SelMethods.ellipticity'
               -H 'temp'
               -Wn '$SelMethods.Wn'
               -Wx '$SelMethods.Wx'
               -A '$SelMethods.Amide'
               -P '$SelMethods.Pathlen'
               -O '$output2'
            #end if 

            #if $SelMethods.Methods == 'PlotData'
               -T '$SelMethods.ellipticity'
               -H 'temp'
               -Wn '$SelMethods.Wn'
               -Wx '$SelMethods.Wx'
               -A '$SelMethods.Amide'
               -P '$SelMethods.Pathlen'
            #end if 

            #if $SelMethods.Methods == 'Dichroweb'
               -T '$SelMethods.ellipticity'
               -H 'temp'
               -Wn '$SelMethods.Wn'
               -Wx '$SelMethods.Wx'
               -A '$SelMethods.Amide'
               -P '$SelMethods.Pathlen'
            #end if

            #if $SelMethods.Methods == 'helicity'
               -H 'temp'
               -Wn '$SelMethods.Wn'
               -Wx '$SelMethods.Wx'
               -A '$SelMethods.Amide'
               -P '$SelMethods.Pathlen'
               -t '$SelMethods.T'
               -k '$SelMethods.K'
               -I '$SelMethods.Induction'
               -O $output1
            #end if

    ]]></command>


  <inputs>

    <param name="input1" label="Input file" type="data" format="csv" multiple="true" argument= "--TrainFile"/>

      <conditional name='SelMethods' >

        <param name="Methods" type="select" label="Circular dichroism data analysis options" help="Circular dichroism data analysis options" >
          <option value="calc_ellipticity">Calculate Ellipticity</option>
          <option value="PlotData">Generate CD Plots</option>
          <option value="Dichroweb">Save Data in DichroWeb Readable Format</option>
          <option value="helicity">Calculate the Percentage of Helicity</option>
        </param>

      <when value="calc_ellipticity">
        <param name="ellipticity" type="select" label="Ellipticity type" argument="-T" help="Methods to calculate the molar ellipticity for all loaded data">
          <option value="calc_molar_ellipticity">Calculate Molar Ellipticity</option>  
          <option value="calc_meanres_ellipticity">Calculate Mean Residue Ellipticity</option>
        </param>
        <param name="Wn" type="integer" value="180" label="Smallest wavelength" argument="-Wn" help="Smallest wavelength measured" />
        <param name="Wx" type="integer" value="260" label="Highest wavelength"   argument="-Wx" help="Highest wavelength measured" />
        <param name="Amide" type="boolean" label="Amide" value="true"  argument="-A" help="Specifies whether the sequences have amidated C-termini" />
        <param name="Pathlen" type="float" label="Pathlen"  value="1.0" argument="--P"  help="Cuvette path length in mm"/>
      </when>

      <when value="PlotData">
        <param name="ellipticity" type="select" label="Which data should be plotted " argument="">
          <option value="mean residue ellipticity">Mean Residue Ellipticity</option>  
          <option value="molar ellipticity">Molar Ellipticity</option>
          <option value="circular dichroism">Circular Dichroism</option>          
        </param>
        <param name="Wn" type="integer" value="180" label="Smallest wavelength" argument="-Wn" help="Smallest wavelength measured" />
        <param name="Wx" type="integer" value="260" label="Highest wavelength"   argument="-Wx" help="Highest wavelength measured" />
        <param name="Amide" type="boolean" label="Amide" value="true"  argument="-A" help="Specifies whether the sequences have amidated C-termini" />
        <param name="Pathlen" type="float" label="Pathlen"  value="1.0" argument="--P"  help="Cuvette path length in mm"/>
      </when>

      <when value="Dichroweb">
        <param name="ellipticity" type="select" label="which data should be return" argument="">
          <option value="mean residue ellipticity">Mean Residue Ellipticity</option>  
          <option value="molar ellipticity">Molar Ellipticity</option>
          <option value="circular dichroism">Circular Dichroism</option>          
        </param>
        <param name="Wn" type="integer" value="260" label="Smallest wavelength" argument="-Wn" help="Smallest wavelength measured" />
        <param name="Wx" type="integer" value="260" label="Highest wavelength"   argument="-Wx" help="Highest wavelength measured" />
        <param name="Amide" type="boolean" label="Amide" value="true"  argument="-A" help="Specifies whether the sequences have amidated C-termini" />
        <param name="Pathlen" type="float" label="Pathlen"  value="1.0" argument="--P"  help="Cuvette path length in mm"/>
      </when>

      <when value="helicity">
        <param name="Wn" type="integer" value="260" label="Smallest wavelength" argument="-Wn" help="Smallest wavelength measured" />
        <param name="Wx" type="integer" value="260" label="Highest wavelength"   argument="-Wx" help="Highest wavelength measured" />
        <param name="Amide" type="boolean" label="Amide" value="true"  argument="-A" help="Specifies whether the sequences have amidated C-termini" />
        <param name="Pathlen" type="float" label="Pathlen"  value="1.0" argument="--P"  help="Cuvette path length in mm"/>
        <param name="T" type="float" label="Temperature"  value="24.0" help="Experiment temperature in C"  argument="-T"/>
        <param name="K" type="float" label="Finite length correction factor" value ="2.4" help="Finite length correction factor" argument="-k" />
        <param name="Induction" type="boolean" label="Induction"  value="true" help="Wether the helical induction upon changing from one solvent to another should be calculated" />
      </when>

    </conditional>
  </inputs>

  <outputs>

    <data name="output1" format="tsv" label="${tool.name} on $on_string - ${SelMethods.Methods} (tabular)" >
      <filter> SelMethods['Methods'] == 'helicity' </filter>
    </data>

    <data name="output2" format="tsv" label="${tool.name} on $on_string - ${SelMethods.Methods} (tabular)" >
      <filter> SelMethods['Methods'] == 'calc_ellipticity' </filter>
    </data>

   <collection name="pdfout" type="list" label="${tool.name} on $on_string - ${SelMethods.Methods} (PDFs)">
      <discover_datasets pattern="__name_and_ext__"  format='pdf' directory="temp/PDF" />
      <filter>   SelMethods['Methods'] == 'PlotData' </filter>
   </collection>


    <collection name="dichroout" type="list" label="${tool.name} on $on_string - ${SelMethods.Methods} (Dichro)">
      <discover_datasets pattern="__name_and_ext__" format='tsv' directory="temp/Dichro" />
        <filter>  SelMethods['Methods'] == 'Dichroweb' </filter>
    </collection>

  </outputs>

  <tests>

    <test>
      <param name="input1" value="Peptide1_T.csv,Peptide2_W.csv" />
      <param name="Methods" value="calc_ellipticity"/>
      <param name="ellipticity" value="calc_molar_ellipticity" />
      <param name="Wn" value="180" />
      <param name="Wx" value="260" />
      <param name="Amide" value="true" />
      <param name="Pathlen" value="1.0" />
      <output name="output1" file="calc_molar_ellipticity.tsv" />
    </test>

    <test>
      <param name="input1" value="Peptide1_T.csv,Peptide2_W.csv" />
      <param name="Methods" value="calc_ellipticity"/>
      <param name="ellipticity" value="calc_meanres_ellipticity" />
      <param name="Wn" value="180" />
      <param name="Wx" value="260" />
      <param name="Amide" value="true" />
      <param name="Pathlen" value="1.0" />
      <output name="output1" file="calc_meanres_ellipticity.tsv" />
    </test>

    <test>
      <param name="input1" value="Peptide1_T.csv,Peptide2_W.csv" />
      <param name="Methods" value="PlotData"/>
      <param name="ellipticity" value="mean residue ellipticity" />
      <param name="Wn" value="180" />
      <param name="Wx" value="260" />
      <param name="Amide" value="false" />
      <param name="Pathlen" value="1.0" />

      <output_collection name="pdfout" count="3"  >
      </output_collection>

  </test>

   <test>
      <param name="input1" value="Peptide1_T.csv,Peptide2_W.csv" />
      <param name="Methods" value="calc_ellipticity"/>
      <param name="ellipticity" value="calc_molar_ellipticity" />
      <param name="Wn" value="180" />
      <param name="Wx" value="260" />
      <param name="Amide" value="true" />
      <param name="Pathlen" value="1.0" />
      <output name="output1" file="calc_molar_ellipticity.tsv" />
    </test>

    <test>
      <param name="input1" value="Peptide1_T.csv,Peptide2_W.csv" />
      <param name="Methods" value="calc_ellipticity"/>
      <param name="ellipticity" value="calc_meanres_ellipticity" />
      <param name="Wn" value="180" />
      <param name="Wx" value="260" />
      <param name="Amide" value="true" />
      <param name="Pathlen" value="1.0" />
      <output name="output1" file="calc_meanres_ellipticity.tsv" />
    </test>



    <test>
      <param name="input1" value="Peptide1_T.csv,Peptide2_W.csv" />
      <param name="Methods" value="PlotData"/>
      <param name="ellipticity" value="mean residue ellipticity" />
      <param name="Wn" value="180" />
      <param name="Wx" value="260" />
      <param name="Amide" value="false" />
      <param name="Pathlen" value="1.0" />
     <output_collection name="pdfout" type="pdf" >
     </output_collection>
    </test>

    <test>
      <param name="input1" value="Peptide1_T.csv,Peptide2_W.csv" />
      <param name="Methods" value="PlotData"/>
      <param name="ellipticity" value="molar ellipticity" />
      <param name="Wn" value="180" />
      <param name="Wx" value="260" />
      <param name="Amide" value="false" />
      <param name="Pathlen" value="1.0" />
     <output_collection name="pdfout" type="pdf" >
     </output_collection>
    </test>

     <test>
      <param name="input1" value="Peptide1_T.csv,Peptide2_W.csv" />
      <param name="Methods" value="PlotData"/>
      <param name="ellipticity" value="circular dichroism" />
      <param name="Wn" value="180" />
      <param name="Wx" value="260" />
      <param name="Amide" value="false" />
      <param name="Pathlen" value="1.0" />
     <output_collection name="pdfout" type="pdf" >
     </output_collection>
    </test>
        <test>
      <param name="input1" value="Peptide1_T.csv,Peptide2_W.csv" />
      <param name="Methods" value="Dichroweb"/>
      <param name="ellipticity" value="mean residue ellipticity" />
      <param name="Wn" value="180" />
      <param name="Wx" value="260" />
      <param name="Amide" value="false" />
      <param name="Pathlen" value="1.0" />
    <output_collection name="dichroout" type="tabular">
    </output_collection>
    </test>

    <test>
      <param name="input1" value="Peptide1_T.csv,Peptide2_W.csv" />
      <param name="Methods" value="Dichroweb"/>
      <param name="ellipticity" value="molar ellipticity" />
      <param name="Wn" value="180" />
      <param name="Wx" value="260" />
      <param name="Amide" value="false" />
      <param name="Pathlen" value="1.0" />
    <output_collection name="dichroout" type="tabular" >
    </output_collection>
    </test>

    <test>
      <param name="input1" value="Peptide1_T.csv,Peptide2_W.csv" />
      <param name="Methods" value="Dichroweb"/>
      <param name="ellipticity" value="circular dichroism" />
      <param name="Wn" value="180" />
      <param name="Wx" value="260" />
      <param name="Amide" value="false" />
      <param name="Pathlen" value="1.0" />
    <output_collection name="dichroout" type="tabular">
    </output_collection>
    </test>

    <test>
      <param name="input1" value="Peptide1_T.csv,Peptide2_W.csv" />
      <param name="Methods" value="helicity"/>
      <param name="Wn" value="180" />
      <param name="Wx" value="260" />
      <param name="Amide" value="false" />
      <param name="Pathlen" value="1.0" />
      <param name="T" value="24" />
      <param name="K" value="3.5" />
      <param name="Induction" value="false" />
      <output name="output1" value="helicity.tsv" />

    </test>

  </tests>

    <help><![CDATA[
.. class:: infomark

**What it does**

This tool handles circular dichroism data files and calculates several ellipticity and helicity values. The class can handle data files of the Applied Photophysics type. For explanations of different units used in CD spectroscopy, visit https://www.photophysics.com/resources/7-cd-units-conversions. Provided with four different options. 

  * **Calculate Ellipticity** Calculates molar and mean residue ellipticity.  
  * **Generate CD Plots** Generates circular_dichroism plots for all read data in the initial directory.
  * **Save Data in DichroWeb Readable Format** Method to save the calculated CD data into DichroWeb readable format (semi-colon separated). The produced files can then directly be uploaded to the DichroWeb analysis tool.
  * **Calculate the Percentage of Helicity<** Method to calculate the percentage of helicity out of the mean residue ellipticity data. The calculation is based on the formula by Fairlie and co-workers.

-----

**Inputs**

  **1** Calculate Ellipticity
     * **--Type**
     * **--Wmin** smallest wavelength measured
     * **--Wmax** highest wavelength measured
     * **--Amide** specifies whether the sequences have amidated C-termini
     * **--Pathlen** cuvette path length in mm

  **2** Generate CD Plots
     * **--Type**
     * **--Wmin** smallest wavelength measured
     * **--Wmax** highest wavelength measured
     * **--Amide** specifies whether the sequences have amidated C-termini
     * **--Pathlen**  cuvette path length in mm

  **3** Save Data in DichroWeb Readable Format
     * **--Type**
     * **--Wmin** smallest wavelength measured
     * **--Wmax** highest wavelength measured
     * **--Amide** specifies whether the sequences have amidated C-termini
     * **--Pathlen**  cuvette path length in mm

  **4** Calculate the Percentage of Helicity 
     * **--Type**
     * **--Wmin** smallest wavelength measured
     * **--Wmax** highest wavelength measured
     * **--Amide** specifies whether the sequences have amidated C-termini
     * **--Pathlen**  cuvette path length in mm
     * **--temperature** experiment temperature in °C
     * **--k** {float, 2.4 - 4.5} finite length correction factor. Can be adapted to the helicity of a known peptide.
     * **--Induction** whether the helical induction upon changing from one solvent to another should be calculated.

-----

**Outputs**
  * **Calculate Ellipticity** Return molar or mean residue ellipticity as a tabular file.  
  * **Plot Data** Returns PDF files.
  * **Save data in DichroWeb readable format** Returns tabular files.
  * **Calculate the percentage of helicity** Returns approximate helicity for every sequence as a tabular file.]]></help>
<citations>
  <citation type="bibtex">
    @misc{PDAUGGITHUB, 
      author = {Joshi, Jayadev  and Blankenberg, Daniel}, 
      year = {2020}, 
      title ={PDAUG - a Galaxy based toolset for peptide library analysis, visualization, and machine learning modeling}, 
      publisher = {GitHub}, 
      journal = {GitHub repository}, 
      url =
      {https://github.com/jaidevjoshi83/pdaug.git}, 
    }
</citation>

<citation type="bibtex">
    @article{müller_gabernet_hiss_schneider_2017, 
      title={modlAMP: Python for antimicrobial peptides}, 
      volume={33}, 
      DOI={10.1093/bioinformatics/btx285}, 
      number={17}, 
      journal={Bioinformatics}, 
      author={Müller, Alex T and Gabernet, Gisela and Hiss, Jan A and Schneider, Gisbert}, 
      year={2017}, 
      pages={2753–2755}
    }
  </citation>
</citations>
</tool>