Maintenance - Mise à jour mensuelle Lundi 6 Avril 2020 entre 7h00 et 9h00

Commit 8a4761c6 authored by Penom Nom's avatar Penom Nom

doc workflow

parent 42f41c3a
......@@ -73,7 +73,7 @@
<li><a href="#casava_ng6workflow">CasavaNG6Workflow</a></li>
</ul>
</li>
<li><a href="#define_parameters">Define parameters</a>
<li><a href="#define_parameters">NG6Workflow.define_parameters()</a>
<ul class="nav nav-stacked">
<li><a href="#parameters">Parameters</a></li>
<li><a href="#input_parameters">Inputs</a></li>
......@@ -81,8 +81,9 @@
<li><a href="#exclusion_rules">Exclusion rules</a></li>
</ul>
</li>
<li><a href="#process">Process</a></li>
<li><a href="#get_resource">Get Resource</a></li>
<li><a href="#process">NG6Workflow.process()</a></li>
<li><a href="#add_component">NG6Workflow.add_component()</a></li>
<li><a href="#get_resource">NG6Workflow.get_ressource()</a></li>
</ul>
</nav>
......@@ -401,7 +402,7 @@ class MyWorkflow (NG6Workflow):
</section>
<section id="define_parameters" class="group">
<h1 class="page-header">Define parameters</h1>
<h1 class="page-header">NG6Workflow.define_parameters()</h1>
<p>
The <code>define_parameters()</code> method is used to add workflow parameters and inputs. To do so, several methods are available.
Once defined, the new parameters are available as object attibuts, thus they are accessible through <code>self.parameter_name</code>.
......@@ -986,17 +987,34 @@ self.add_exclution_rule("fasta_file", "fastq")</code></pre>
</section>
<section id="process" class="group">
<h1 class="page-header">Process</h1>
<h1 class="page-header">NG6Workflow.process()</h1>
<p>The <code>process()</code> method is in charge of building the workflow by adding analyses and components (using the method <code>add_component()</code>) and
linking their inputs and their outputs. A analaysis and a component are classes representing a workflow step. See the
<a href="./core-component.html">analyses</a> documentation for more information.</p>
<h2>add_component()</h2>
<p>The <code>add_component()</code> method add an analysis or a component to the workflow by building respectively a <code>ng6.analysis.Analysis</code>
<h2>Example</h2>
<div>
<pre class="pre-hl "><code class="python">def process(self):
# index the reference genome
bwaindex = self.add_component("BWAIndex", [self.reference_genome])
# align reads against the indexed genome
bwamem = self.add_component("BWAmem", [bwaindex.databank, self.reads])</code></pre>
</div>
<h2>Options</h2>
<p>No options</p>
</section>
<section id="add_component" class="group">
<h1 class="page-header">NG6Workflow.add_component()</h1>
<p>The <code>add_component()</code> method add an analysis or a component to the workflow by building respectively a <code>ng6.analysis.Analysis</code>
or a <code>jflow.component.Component</code> object and returning it. All attributs defined within this object, such as the outputs,
are then available from the workflow and can be used as inputs of other components.</p>
<h3>Example</h3>
<h2>Example</h2>
<p>In the following example, the first component <code>BWAIndex</code> is built and returned in the <code>bwaindex</code> object.
The output <code>bwaindex.databank</code> is accessible as an object attribut and can be used as input of the <code>BWAmem</code>
component.</p>
......@@ -1006,7 +1024,7 @@ bwaindex = self.add_component("BWAIndex", [self.reference_genome])
# align reads against the indexed genome
bwamem = self.add_component("BWAmem", [bwaindex.databank, self.reads])</code></pre>
</div>
<h3>Options</h3>
<h2>Options</h2>
<p>There is one positional argument : component_name. All other options are keyword options.</p>
<div class="table-responsive">
<table class="table table-bordered table-striped">
......@@ -1052,10 +1070,15 @@ bwamem = self.add_component("BWAmem", [bwaindex.databank, self.reads])</code></p
</tbody>
</table>
</div>
</section>
<section id="get_resource" class="group">
<h1 class="page-header">Get shared resources</h1>
<h1 class="page-header">NG6Workflow.get_resource()</h1>
<p>The method <code>get_resource()</code>, giving a specific resource, returns the defined value within the <code>resource</code>
section of the jflow configuration file.</p>
<h3>Options</h3>
......@@ -1082,7 +1105,6 @@ bwamem = self.add_component("BWAmem", [bwaindex.databank, self.reads])</code></p
</tbody>
</table>
</div>
</div>
</section>
</div>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment