diff nanopolish_methylation.xml @ 0:f9dadc362197 draft

planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/nanopolish commit 0e94011a4ea84bf4ae5c2079680a37540e022625
author bgruening
date Wed, 30 May 2018 11:55:55 -0400
parents
children 709490665bad
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/nanopolish_methylation.xml	Wed May 30 11:55:55 2018 -0400
@@ -0,0 +1,72 @@
+<tool id="nanopolish_methylation" name="Nanopolish methylation" version="0.1.0">
+    <description>- Classify nucleotides as methylated or not.</description>
+    <macros>
+        <import>macros.xml</import>
+    </macros>
+    <expand macro="requirements" />
+    <command detect_errors="exit_code"><![CDATA[
+        ln -s '$input_merged' reads.fasta && 
+        
+        #if $input_reads_raw.extension == 'fast5':
+            mkdir fast5_files && ln -s '$input_reads_raw' fast5_files/read1.fast5 &&
+        #else
+            ln -s '$input_reads_raw' fast5_files.tar.gz &&
+            mkdir fast5_files && tar -xzf fast5_files.tar.gz -C fast5_files &&
+        #end if
+
+        nanopolish index -d fast5_files/ reads.fasta &&
+        ln -s '$b' reads.bam &&
+        ln -s '${b.metadata.bam_index}' reads.bam.bai &&
+        ln -s '$g' genome.fa &&
+        
+        nanopolish call-methylation
+        -r reads.fasta
+        -b reads.bam
+        -g genome.fa
+        #if $w and str($w).strip():
+          -w "${w}"
+        #end if  
+        > methylation_calls.tsv
+    ]]></command>
+    <inputs>
+      <!-- index inputs -->
+        <param type="data" name="input_merged" format="fasta,fastq" label="Basecalled merged reads.fa"/>
+        <param type="data" name="input_reads_raw" format="h5,fast5.tar.gz" label="Flat archive file of raw fast5 files"/>
+
+        <!-- variants consensus inputs -->
+        <param type="data" argument="-b" format="bam" label="Reads aligned to the reference genome" />
+        <param type="data" argument="-g" format="fasta" label="The reference genome"/>
+
+        <param argument="-w" type="text" optional="true"
+            label="find variants in window of region chromsome:start-end" />
+
+    </inputs>
+
+    <outputs>
+      <!-- variants consensus outputs -->
+        <data name="output_methylation_calls" format="tabular" from_work_dir="methylation_calls.tsv" label="called methylation sites" />
+    </outputs>
+    <tests>
+        <test>
+      <!-- index test -->
+            <param name="input_merged" ftype="fasta" value="reads.fasta" />
+            <param name="input_reads_raw" ftype="fast5.tar.gz" value="fast5_files.tar.gz" />
+            
+      <!-- variants consensus test -->
+            <param name="b" value="reads.sorted.bam" />
+            <param name="g" value="draft.fa" />
+            <param name="w" value="tig00000001:200000-202000" />
+            
+            <output name="output_methylation_calls" file="methylation_calls.tsv" />
+        </test>
+    </tests>
+    <help><![CDATA[
+        Usage: nanopolish call-methylation [OPTIONS] --reads reads.fa --bam alignments.bam --genome genome.fa
+        Classify nucleotides as methylated or not.
+        
+        Quickstart tutorial and manual available at:
+        http://nanopolish.readthedocs.io/en/latest/quickstart_call_methylation.html
+
+    ]]></help>
+    <expand macro="citations" />
+</tool>