diff draw_amr_matrix.xml @ 2:9fcc1ffd7526 draft

Uploaded
author greg
date Fri, 10 Feb 2023 17:27:33 +0000
parents 6044ca44e9f6
children 33a0ea992043
line wrap: on
line diff
--- a/draw_amr_matrix.xml	Fri Feb 10 17:27:13 2023 +0000
+++ b/draw_amr_matrix.xml	Fri Feb 10 17:27:33 2023 +0000
@@ -7,26 +7,29 @@
     <command detect_errors="exit_code"><![CDATA[
 #import re
 
-mkdir feature_hits_dir &&
+mkdir amr_feature_hits_dir &&
 mkdir output_dir &&
 
-#for $i in $feature_hits:
+#for $i in $amr_feature_hits:
     #set file_name = $i.file_name
     #set identifier = re.sub('[^\s\w\-\\.]', '_', str($i.element_identifier))
-    ln -s '$file_name' 'feature_hits_dir/$identifier' &&
+    ln -s '$file_name' 'amr_feature_hits_dir/$identifier' &&
 #end for
 
 python '$__tool_directory__/draw_amr_matrix.py'
---amr_gene_drug '$amr_gene_drug'
---feature_hits_dir 'feature_hits_dir'
+--amr_gene_drug_file '$amr_gene_drug_file'
+--amr_deletions_file '$amr_deletions_file'
+--amr_feature_hits_dir 'amr_feature_hits_dir'
 --output_dir 'output_dir'
 #if str($output_process_log) == 'yes':
     && mv 'process_log' '$process_log'
 #end if
 ]]></command>
     <inputs>
-        <param argument="--amr_gene_drug" type="data" format="tabular,tsv" label="Tabular AMR gene drugs file"/>
-        <param argument="--feature_hits" format="bed" type="data_collection" collection_type="list" label="Collection of feature hits BED files"/>
+        <param argument="--amr_feature_hits" format="bed" type="data_collection" collection_type="list" label="Collection of feature hits BED files"/>
+        <param argument="--amr_deletions_file" type="data" format="bed" optional="true" label="AMR deletions file" help="Optional, leave blank to ignore"/>
+        <param argument="--amr_mutations_file" type="data" format="tabular,tsv" optional="true" label="AMR mutations file" help="Optional, leave blank to ignore"/>
+        <param argument="--amr_gene_drug_file" type="data" format="tabular,tsv" label="AMR gene drugs file"/>
         <param name="output_process_log" type="select" display="radio" label="Output process log file?">
             <option value="no" selected="true">No</option>
             <option value="yes">Yes</option>
@@ -42,16 +45,16 @@
     </outputs>
     <tests>
         <test>
-            <param name="amr_gene_drug" value="amr_gene_drug.tsv" ftype="tsv"/>
-            <param name="feature_hits">
+            <param name="amr_feature_hits">
                 <collection type="list">
-                    <element name="amr_pima_md" value="amr_pima_md.bed"/>
+                    <element name="amr_cds.bed" value="amr_cds.bed"/>
                 </collection>
             </param>
+            <param name="amr_gene_drug_file" value="amr_gene_drug.tsv" ftype="tsv"/>
             <output_collection name="amr_matrix_png" type="list" count="1">
-                <element name="amr_matrix" ftype="png">
+                <element name="contig_1" ftype="png">
                     <assert_contents>
-                        <has_size value="38309" delta="500"/>
+                        <has_size value="25383" delta="100"/>
                     </assert_contents>
                 </element>
             </output_collection>
@@ -60,7 +63,8 @@
     <help>
 **What it does**
 
-Accepts a tabular AMR gene drugs file and a collection of best feature hits and draws an AMR matrix.
+Accepts a collection of best AMR feature hits, an optional AMR deletions BED file, an optional AMR mutations TSV file and a AMR gene
+drug mappings file and draws an AMR matrix.
     </help>
     <expand macro="citations"/>
 </tool>