diff Sbml2Graph.xml @ 0:5e7aa3ae9c16 draft

planemo upload for repository https://forgemia.inra.fr/metexplore/met4j-galaxy commit e28ca123295d50b85ba872e5a4720fd72697ecc3
author metexplore
date Thu, 13 Mar 2025 15:49:33 +0000
parents
children a06c047410ac
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Sbml2Graph.xml	Thu Mar 13 15:49:33 2025 +0000
@@ -0,0 +1,76 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<tool id="met4j_Sbml2Graph" name="Sbml2Graph" version="@TOOL_VERSION@">
+  <description>Create a graph representation of a SBML file content, and export it in graph file format.</description>
+  <macros>
+    <import>macros.xml</import>
+  </macros>
+  <expand macro="bio_tools"/>
+  <expand macro="requirements"/>
+  <command detect_errors="exit_code"><![CDATA[met4j fr.inrae.toulouse.metexplore.met4j_toolbox.convert.Sbml2Graph -i "$inputPath"
+ $bipartite
+ $compound
+ $reaction
+#if str($format):
+ -f "$format"
+#end if
+ -o "$output"
+]]></command>
+  <inputs>
+    <param argument="-i" format="sbml" label="input SBML file" name="inputPath" optional="false" type="data" value=""/>
+    <param argument="-b" checked="false" falsevalue="" label="create bipartite graph" name="bipartite" truevalue="-b" type="boolean" value="false"/>
+    <param argument="-c" checked="true" falsevalue="" label="create compound graph" name="compound" truevalue="-c" type="boolean" value="true"/>
+    <param argument="-r" checked="false" falsevalue="" label="create reaction graph" name="reaction" truevalue="-r" type="boolean" value="false"/>
+    <param argument="-f" label="Format of the exported graphTabulated edge list by default (source id &#9; edge type &#9; target id). Other options include GML, JsonGraph, and tabulated node list (label &#9; node id &#9; node type)." name="format" optional="true" type="select" value="tab">
+      <option value="gml">gml</option>
+      <option selected="true" value="tab">tab</option>
+      <option value="nodeList">nodeList</option>
+      <option value="json">json</option>
+      <option value="matrix">matrix</option>
+    </param>
+  </inputs>
+  <outputs>
+    <data format="txt" name="output"/>
+  </outputs>
+  <tests>
+    <test>
+      <param name="inputPath" value="toy_model.xml"/>
+      <param name="format" value="gml"/>
+      <output name="output">
+        <assert_contents>
+          <has_line_matching expression=".*node.*" n="8"/>
+          <has_line_matching expression=".*edge.*" n="9"/>
+        </assert_contents>
+      </output>
+    </test>
+    <test>
+      <param name="inputPath" value="toy_model.xml"/>
+      <param name="bipartite" value="true"/>
+      <param name="compound" value="false"/>
+      <param name="format" value="gml"/>
+      <output name="output">
+        <assert_contents>
+          <has_line_matching expression=".*node.*" n="15"/>
+          <has_line_matching expression=".*edge.*" n="17"/>
+        </assert_contents>
+      </output>
+    </test>
+    <test>
+      <param name="inputPath" value="toy_model.xml"/>
+      <param name="reaction" value="true"/>
+      <param name="compound" value="false"/>
+      <param name="format" value="gml"/>
+      <output name="output">
+        <assert_contents>
+          <has_line_matching expression=".*node.*" n="7"/>
+          <has_line_matching expression=".*edge.*" n="8"/>
+        </assert_contents>
+      </output>
+    </test>
+  </tests>
+  <help><![CDATA[Create a graph representation of a SBML file content, and export it in graph file format.
+The graph can be either a compound graph, a reaction graph or a bipartite graph, and can be exported in gml or tabulated file format.
+@ATTRIBUTION@]]></help>
+  <citations>
+    <citation type="doi">10.1109/tcbb.2008.79</citation>
+  </citations>
+</tool>