From a0babc8304cbaebb71ea584b163923f0605e007b Mon Sep 17 00:00:00 2001
From: Maciej Bak <maciej.bak@unibas.ch>
Date: Thu, 12 Mar 2020 14:43:27 +0100
Subject: [PATCH] add TIN score merge and plot steps

---
 Snakefile                      | 116 ++++++++-
 images/rule_graph.svg          | 416 +++++++++++++++++----------------
 tests/input_files/cluster.json |  12 +
 3 files changed, 334 insertions(+), 210 deletions(-)

diff --git a/Snakefile b/Snakefile
index 7c8185c..62b7278 100644
--- a/Snakefile
+++ b/Snakefile
@@ -64,17 +64,12 @@ rule finish:
             sample=[i for i in list(samples_table.index.values)],
             seqmode=[samples_table.loc[i, 'seqmode']
                      for i in list(samples_table.index.values)]),
-        TIN_score = expand(
-            os.path.join(
-                config['output_dir'],
-                "{seqmode}",
-                "{sample}",
-                "TIN",
-                "TIN_score.tsv"),
-            zip,
-            sample=[i for i in list(samples_table.index.values)],
-            seqmode=[samples_table.loc[i, 'seqmode']
-                     for i in list(samples_table.index.values)]),
+        TIN_boxplot_PNG = os.path.join(
+            config['output_dir'],
+            "TIN_scores_boxplot.png"),
+        TIN_boxplot_PDF = os.path.join(
+            config['output_dir'],
+            "TIN_scores_boxplot.pdf"),
         salmon_merge_genes = expand(
             os.path.join(
                 config["output_dir"],
@@ -483,7 +478,7 @@ rule calculate_TIN_scores:
     threads: 8
 
     singularity:
-        "docker://zavolab/tin_score_calculation:0.1.0-slim"
+        "docker://zavolab/tin_score_calculation:0.2.0-slim"
 
     shell:
         "(tin_score_calculation.py \
@@ -494,6 +489,103 @@ rule calculate_TIN_scores:
         -n 100 > {output.TIN_score};) 2> {log.stderr}"
 
 
+rule merge_TIN_scores:
+    """
+        Merge TIN scores tables
+    """
+    input:
+        TIN_score = expand(
+            os.path.join(
+                config['output_dir'],
+                "{seqmode}",
+                "{sample}",
+                "TIN",
+                "TIN_score.tsv"),
+            zip,
+            sample=[i for i in list(samples_table.index.values)],
+            seqmode=[samples_table.loc[i, 'seqmode']
+                     for i in list(samples_table.index.values)])
+
+    output:
+        TIN_scores_merged = os.path.join(
+            config['output_dir'],
+            "TIN_scores_merged.tsv")
+
+    params:
+        TIN_score_merged_paths = ",".join(expand(
+            os.path.join(
+                config['output_dir'],
+                "{seqmode}",
+                "{sample}",
+                "TIN",
+                "TIN_score.tsv"),
+            zip,
+            sample=[i for i in list(samples_table.index.values)],
+            seqmode=[samples_table.loc[i, 'seqmode']
+                     for i in list(samples_table.index.values)]))
+
+    log:
+        stderr = os.path.join(
+            config['log_dir'],
+            "merge_TIN_scores.stderr.log"),
+        stdout = os.path.join(
+            config["log_dir"],
+            "merge_TIN_scores.stdout.log")
+
+    threads: 1
+
+    singularity:
+        "docker://zavolab/tin_score_calculation:0.2.0-slim"
+
+    shell:
+        "(tin_score_merge.py \
+        --input-files {params.TIN_score_merged_paths} \
+        --output-file {output.TIN_scores_merged}) \
+        1> {log.stdout} 2> {log.stderr}"
+
+
+rule plot_TIN_scores:
+    """
+        Generate TIN scores boxplots
+    """
+    input:
+        TIN_scores_merged = os.path.join(
+            config['output_dir'],
+            "TIN_scores_merged.tsv"),
+
+    output:
+        TIN_boxplot_PNG = os.path.join(
+            config['output_dir'],
+            "TIN_scores_boxplot.png"),
+        TIN_boxplot_PDF = os.path.join(
+            config['output_dir'],
+            "TIN_scores_boxplot.pdf")
+
+    params:
+        TIN_boxplot_prefix = os.path.join(
+            config['output_dir'],
+            "TIN_scores_boxplot")
+
+    log:
+        stderr = os.path.join(
+            config['log_dir'],
+            "plot_TIN_scores.stderr.log"),
+        stdout = os.path.join(
+            config["log_dir"],
+            "plot_TIN_scores.stdout.log")
+
+    threads: 1
+
+    singularity:
+        "docker://zavolab/tin_score_calculation:0.2.0-slim"
+
+    shell:
+        "(tin_score_plot.py \
+        --input-file {input.TIN_scores_merged} \
+        --output-file-prefix {params.TIN_boxplot_prefix}) \
+        1> {log.stdout} 2> {log.stderr}"
+
+
 rule salmon_quantmerge_genes:
     '''
         Merge gene quantifications into a single file
diff --git a/images/rule_graph.svg b/images/rule_graph.svg
index a2a0d00..4fed3d2 100644
--- a/images/rule_graph.svg
+++ b/images/rule_graph.svg
@@ -4,310 +4,330 @@
 <!-- Generated by graphviz version 2.38.0 (20140413.2041)
  -->
 <!-- Title: snakemake_dag Pages: 1 -->
-<svg width="1071pt" height="404pt"
- viewBox="0.00 0.00 1070.98 404.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
-<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 400)">
+<svg width="873pt" height="548pt"
+ viewBox="0.00 0.00 873.02 548.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
+<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 544)">
 <title>snakemake_dag</title>
-<polygon fill="white" stroke="none" points="-4,4 -4,-400 1066.98,-400 1066.98,4 -4,4"/>
+<polygon fill="white" stroke="none" points="-4,4 -4,-544 869.023,-544 869.023,4 -4,4"/>
 <!-- 0 -->
 <g id="node1" class="node"><title>0</title>
-<path fill="none" stroke="#56c9d8" stroke-width="2" d="M304,-36C304,-36 274,-36 274,-36 268,-36 262,-30 262,-24 262,-24 262,-12 262,-12 262,-6 268,-0 274,-0 274,-0 304,-0 304,-0 310,-0 316,-6 316,-12 316,-12 316,-24 316,-24 316,-30 310,-36 304,-36"/>
-<text text-anchor="middle" x="289" y="-15.5" font-family="sans" font-size="10.00">finish</text>
+<path fill="none" stroke="#56a9d8" stroke-width="2" d="M334,-36C334,-36 304,-36 304,-36 298,-36 292,-30 292,-24 292,-24 292,-12 292,-12 292,-6 298,-0 304,-0 304,-0 334,-0 334,-0 340,-0 346,-6 346,-12 346,-12 346,-24 346,-24 346,-30 340,-36 334,-36"/>
+<text text-anchor="middle" x="319" y="-15.5" font-family="sans" font-size="10.00">finish</text>
 </g>
 <!-- 1 -->
 <g id="node2" class="node"><title>1</title>
-<path fill="none" stroke="#56d892" stroke-width="2" d="M85.5,-108C85.5,-108 50.5,-108 50.5,-108 44.5,-108 38.5,-102 38.5,-96 38.5,-96 38.5,-84 38.5,-84 38.5,-78 44.5,-72 50.5,-72 50.5,-72 85.5,-72 85.5,-72 91.5,-72 97.5,-78 97.5,-84 97.5,-84 97.5,-96 97.5,-96 97.5,-102 91.5,-108 85.5,-108"/>
-<text text-anchor="middle" x="68" y="-87.5" font-family="sans" font-size="10.00">pe_fastqc</text>
+<path fill="none" stroke="#88d856" stroke-width="2" d="M149.5,-108C149.5,-108 114.5,-108 114.5,-108 108.5,-108 102.5,-102 102.5,-96 102.5,-96 102.5,-84 102.5,-84 102.5,-78 108.5,-72 114.5,-72 114.5,-72 149.5,-72 149.5,-72 155.5,-72 161.5,-78 161.5,-84 161.5,-84 161.5,-96 161.5,-96 161.5,-102 155.5,-108 149.5,-108"/>
+<text text-anchor="middle" x="132" y="-87.5" font-family="sans" font-size="10.00">pe_fastqc</text>
 </g>
 <!-- 1&#45;&gt;0 -->
-<g id="edge8" class="edge"><title>1&#45;&gt;0</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M97.6525,-75.6092C100.786,-74.3338 103.944,-73.1059 107,-72 156.36,-54.1377 214.865,-37.9591 251.957,-28.3004"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="253.018,-31.6413 261.826,-25.753 251.268,-24.8635 253.018,-31.6413"/>
+<g id="edge2" class="edge"><title>1&#45;&gt;0</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M161.724,-75.7983C164.844,-74.4861 167.979,-73.1978 171,-72 208.496,-57.1332 252.026,-41.7675 282.125,-31.434"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="283.459,-34.6769 291.789,-28.1305 281.195,-28.0531 283.459,-34.6769"/>
 </g>
 <!-- 2 -->
 <g id="node3" class="node"><title>2</title>
-<path fill="none" stroke="#d8b456" stroke-width="2" d="M158,-108C158,-108 128,-108 128,-108 122,-108 116,-102 116,-96 116,-96 116,-84 116,-84 116,-78 122,-72 128,-72 128,-72 158,-72 158,-72 164,-72 170,-78 170,-84 170,-84 170,-96 170,-96 170,-102 164,-108 158,-108"/>
-<text text-anchor="middle" x="143" y="-87.5" font-family="sans" font-size="10.00">fastqc</text>
+<path fill="none" stroke="#56d863" stroke-width="2" d="M222,-108C222,-108 192,-108 192,-108 186,-108 180,-102 180,-96 180,-96 180,-84 180,-84 180,-78 186,-72 192,-72 192,-72 222,-72 222,-72 228,-72 234,-78 234,-84 234,-84 234,-96 234,-96 234,-102 228,-108 222,-108"/>
+<text text-anchor="middle" x="207" y="-87.5" font-family="sans" font-size="10.00">fastqc</text>
 </g>
 <!-- 2&#45;&gt;0 -->
-<g id="edge7" class="edge"><title>2&#45;&gt;0</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M170.119,-75.9976C193.328,-64.8701 226.942,-48.7539 252.509,-36.4956"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="254.026,-39.6497 261.53,-32.1703 251,-33.3377 254.026,-39.6497"/>
+<g id="edge1" class="edge"><title>2&#45;&gt;0</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M234.112,-72.055C248.861,-62.8371 267.29,-51.3185 283.206,-41.3715"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="285.124,-44.2997 291.749,-36.0316 281.414,-38.3637 285.124,-44.2997"/>
 </g>
 <!-- 3 -->
 <g id="node4" class="node"><title>3</title>
-<path fill="none" stroke="#56d8a2" stroke-width="2" d="M322,-252C322,-252 180,-252 180,-252 174,-252 168,-246 168,-240 168,-240 168,-228 168,-228 168,-222 174,-216 180,-216 180,-216 322,-216 322,-216 328,-216 334,-222 334,-228 334,-228 334,-240 334,-240 334,-246 328,-252 322,-252"/>
-<text text-anchor="middle" x="251" y="-231.5" font-family="sans" font-size="10.00">pe_genome_quantification_kallisto</text>
+<path fill="none" stroke="#d89556" stroke-width="2" d="M434,-396C434,-396 292,-396 292,-396 286,-396 280,-390 280,-384 280,-384 280,-372 280,-372 280,-366 286,-360 292,-360 292,-360 434,-360 434,-360 440,-360 446,-366 446,-372 446,-372 446,-384 446,-384 446,-390 440,-396 434,-396"/>
+<text text-anchor="middle" x="363" y="-375.5" font-family="sans" font-size="10.00">pe_genome_quantification_kallisto</text>
 </g>
 <!-- 3&#45;&gt;0 -->
-<g id="edge1" class="edge"><title>3&#45;&gt;0</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M250.655,-215.826C250.553,-197.82 251.126,-168.755 255,-144 260.41,-109.434 271.8,-70.7187 279.905,-45.6614"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="283.24,-46.7217 283.043,-36.1287 276.591,-44.5326 283.24,-46.7217"/>
+<g id="edge6" class="edge"><title>3&#45;&gt;0</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M357.941,-359.684C350.636,-333.11 338,-280.558 338,-235 338,-235 338,-235 338,-161 338,-120.86 330.449,-74.897 324.868,-46.4045"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="328.255,-45.4976 322.845,-36.3884 321.394,-46.8834 328.255,-45.4976"/>
 </g>
 <!-- 4 -->
 <g id="node5" class="node"><title>4</title>
-<path fill="none" stroke="#8fd856" stroke-width="2" d="M138,-252C138,-252 12,-252 12,-252 6,-252 1.42109e-14,-246 1.42109e-14,-240 1.42109e-14,-240 1.42109e-14,-228 1.42109e-14,-228 1.42109e-14,-222 6,-216 12,-216 12,-216 138,-216 138,-216 144,-216 150,-222 150,-228 150,-228 150,-240 150,-240 150,-246 144,-252 138,-252"/>
-<text text-anchor="middle" x="75" y="-231.5" font-family="sans" font-size="10.00">genome_quantification_kallisto</text>
+<path fill="none" stroke="#9fd856" stroke-width="2" d="M602,-396C602,-396 476,-396 476,-396 470,-396 464,-390 464,-384 464,-384 464,-372 464,-372 464,-366 470,-360 476,-360 476,-360 602,-360 602,-360 608,-360 614,-366 614,-372 614,-372 614,-384 614,-384 614,-390 608,-396 602,-396"/>
+<text text-anchor="middle" x="539" y="-375.5" font-family="sans" font-size="10.00">genome_quantification_kallisto</text>
 </g>
 <!-- 4&#45;&gt;0 -->
-<g id="edge6" class="edge"><title>4&#45;&gt;0</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M92.1508,-215.849C130.029,-177.971 220.923,-87.0767 264.668,-43.3318"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="267.171,-45.7784 271.768,-36.2325 262.222,-40.8287 267.171,-45.7784"/>
+<g id="edge8" class="edge"><title>4&#45;&gt;0</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M482.882,-359.975C462.24,-351.633 439.823,-339.886 423,-324 390.476,-293.288 376,-279.732 376,-235 376,-235 376,-235 376,-161 376,-117.801 353,-72.1859 336.22,-44.6553"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="339.093,-42.6485 330.81,-36.0417 333.165,-46.3716 339.093,-42.6485"/>
 </g>
 <!-- 5 -->
 <g id="node6" class="node"><title>5</title>
-<path fill="none" stroke="#a7d856" stroke-width="2" d="M876,-108C876,-108 788,-108 788,-108 782,-108 776,-102 776,-96 776,-96 776,-84 776,-84 776,-78 782,-72 788,-72 788,-72 876,-72 876,-72 882,-72 888,-78 888,-84 888,-84 888,-96 888,-96 888,-102 882,-108 876,-108"/>
-<text text-anchor="middle" x="832" y="-87.5" font-family="sans" font-size="10.00">calculate_TIN_scores</text>
+<path fill="none" stroke="#56c1d8" stroke-width="2" d="M499.5,-108C499.5,-108 434.5,-108 434.5,-108 428.5,-108 422.5,-102 422.5,-96 422.5,-96 422.5,-84 422.5,-84 422.5,-78 428.5,-72 434.5,-72 434.5,-72 499.5,-72 499.5,-72 505.5,-72 511.5,-78 511.5,-84 511.5,-84 511.5,-96 511.5,-96 511.5,-102 505.5,-108 499.5,-108"/>
+<text text-anchor="middle" x="467" y="-87.5" font-family="sans" font-size="10.00">plot_TIN_scores</text>
 </g>
 <!-- 5&#45;&gt;0 -->
-<g id="edge5" class="edge"><title>5&#45;&gt;0</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M775.935,-81.7724C664.916,-67.4607 419.77,-35.8579 326.247,-23.8017"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="326.492,-20.3043 316.126,-22.4969 325.597,-27.2469 326.492,-20.3043"/>
+<g id="edge3" class="edge"><title>5&#45;&gt;0</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M430.795,-71.8761C407.78,-60.9904 378.097,-46.9511 355.101,-36.0749"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="356.549,-32.8878 346.012,-31.7761 353.556,-39.2157 356.549,-32.8878"/>
 </g>
 <!-- 6 -->
 <g id="node7" class="node"><title>6</title>
-<path fill="none" stroke="#56d8b9" stroke-width="2" d="M562,-180C562,-180 450,-180 450,-180 444,-180 438,-174 438,-168 438,-168 438,-156 438,-156 438,-150 444,-144 450,-144 450,-144 562,-144 562,-144 568,-144 574,-150 574,-156 574,-156 574,-168 574,-168 574,-174 568,-180 562,-180"/>
-<text text-anchor="middle" x="506" y="-159.5" font-family="sans" font-size="10.00">salmon_quantmerge_genes</text>
+<path fill="none" stroke="#56d873" stroke-width="2" d="M124,-324C124,-324 12,-324 12,-324 6,-324 0,-318 0,-312 0,-312 0,-300 0,-300 0,-294 6,-288 12,-288 12,-288 124,-288 124,-288 130,-288 136,-294 136,-300 136,-300 136,-312 136,-312 136,-318 130,-324 124,-324"/>
+<text text-anchor="middle" x="68" y="-303.5" font-family="sans" font-size="10.00">salmon_quantmerge_genes</text>
 </g>
 <!-- 6&#45;&gt;0 -->
-<g id="edge2" class="edge"><title>6&#45;&gt;0</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M479.825,-143.871C440.805,-118.338 367.323,-70.253 323.813,-41.7808"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="325.552,-38.7362 315.268,-36.1893 321.719,-44.5936 325.552,-38.7362"/>
+<g id="edge4" class="edge"><title>6&#45;&gt;0</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M83.3284,-287.971C113.904,-253.955 184.56,-175.096 243,-108 261.747,-86.4755 282.806,-61.7729 297.993,-43.8623"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="300.736,-46.0396 304.529,-36.1469 295.395,-41.5151 300.736,-46.0396"/>
 </g>
 <!-- 7 -->
 <g id="node8" class="node"><title>7</title>
-<path fill="none" stroke="#56d87b" stroke-width="2" d="M407.5,-180C407.5,-180 276.5,-180 276.5,-180 270.5,-180 264.5,-174 264.5,-168 264.5,-168 264.5,-156 264.5,-156 264.5,-150 270.5,-144 276.5,-144 276.5,-144 407.5,-144 407.5,-144 413.5,-144 419.5,-150 419.5,-156 419.5,-156 419.5,-168 419.5,-168 419.5,-174 413.5,-180 407.5,-180"/>
-<text text-anchor="middle" x="342" y="-159.5" font-family="sans" font-size="10.00">salmon_quantmerge_transcripts</text>
+<path fill="none" stroke="#5682d8" stroke-width="2" d="M297.5,-324C297.5,-324 166.5,-324 166.5,-324 160.5,-324 154.5,-318 154.5,-312 154.5,-312 154.5,-300 154.5,-300 154.5,-294 160.5,-288 166.5,-288 166.5,-288 297.5,-288 297.5,-288 303.5,-288 309.5,-294 309.5,-300 309.5,-300 309.5,-312 309.5,-312 309.5,-318 303.5,-324 297.5,-324"/>
+<text text-anchor="middle" x="232" y="-303.5" font-family="sans" font-size="10.00">salmon_quantmerge_transcripts</text>
 </g>
 <!-- 7&#45;&gt;0 -->
-<g id="edge4" class="edge"><title>7&#45;&gt;0</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M335.607,-143.871C326.495,-119.457 309.687,-74.4258 298.941,-45.6351"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="302.192,-44.3341 295.416,-36.1893 295.633,-46.7819 302.192,-44.3341"/>
+<g id="edge5" class="edge"><title>7&#45;&gt;0</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M250.018,-287.971C259.195,-278.286 269.715,-265.431 276,-252 308.374,-182.818 316.407,-91.4095 318.377,-46.4173"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="321.88,-46.3955 318.751,-36.2734 314.885,-46.1376 321.88,-46.3955"/>
 </g>
 <!-- 8 -->
 <g id="node9" class="node"><title>8</title>
-<path fill="none" stroke="#d85656" stroke-width="2" d="M675.5,-108C675.5,-108 644.5,-108 644.5,-108 638.5,-108 632.5,-102 632.5,-96 632.5,-96 632.5,-84 632.5,-84 632.5,-78 638.5,-72 644.5,-72 644.5,-72 675.5,-72 675.5,-72 681.5,-72 687.5,-78 687.5,-84 687.5,-84 687.5,-96 687.5,-96 687.5,-102 681.5,-108 675.5,-108"/>
-<text text-anchor="middle" x="660" y="-87.5" font-family="sans" font-size="10.00">star_rpm</text>
+<path fill="none" stroke="#c6d856" stroke-width="2" d="M765.5,-252C765.5,-252 734.5,-252 734.5,-252 728.5,-252 722.5,-246 722.5,-240 722.5,-240 722.5,-228 722.5,-228 722.5,-222 728.5,-216 734.5,-216 734.5,-216 765.5,-216 765.5,-216 771.5,-216 777.5,-222 777.5,-228 777.5,-228 777.5,-240 777.5,-240 777.5,-246 771.5,-252 765.5,-252"/>
+<text text-anchor="middle" x="750" y="-231.5" font-family="sans" font-size="10.00">star_rpm</text>
 </g>
 <!-- 8&#45;&gt;0 -->
-<g id="edge3" class="edge"><title>8&#45;&gt;0</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M632.418,-83.7958C566.659,-71.3886 400.61,-40.0585 326.141,-26.0077"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="326.736,-22.5583 316.261,-24.1435 325.438,-29.437 326.736,-22.5583"/>
+<g id="edge7" class="edge"><title>8&#45;&gt;0</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M730.968,-215.978C693.481,-183.32 606.294,-111.602 521,-72 466.432,-46.6639 397.734,-31.905 356.151,-24.6562"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="356.632,-21.1879 346.188,-22.9733 355.466,-28.0901 356.632,-21.1879"/>
 </g>
 <!-- 9 -->
 <g id="node10" class="node"><title>9</title>
-<path fill="none" stroke="#56b1d8" stroke-width="2" d="M649,-324C649,-324 537,-324 537,-324 531,-324 525,-318 525,-312 525,-312 525,-300 525,-300 525,-294 531,-288 537,-288 537,-288 649,-288 649,-288 655,-288 661,-294 661,-300 661,-300 661,-312 661,-312 661,-318 655,-324 649,-324"/>
-<text text-anchor="middle" x="593" y="-303.5" font-family="sans" font-size="10.00">pe_remove_polya_cutadapt</text>
+<path fill="none" stroke="#d86e56" stroke-width="2" d="M362,-468C362,-468 250,-468 250,-468 244,-468 238,-462 238,-456 238,-456 238,-444 238,-444 238,-438 244,-432 250,-432 250,-432 362,-432 362,-432 368,-432 374,-438 374,-444 374,-444 374,-456 374,-456 374,-462 368,-468 362,-468"/>
+<text text-anchor="middle" x="306" y="-447.5" font-family="sans" font-size="10.00">pe_remove_polya_cutadapt</text>
 </g>
 <!-- 9&#45;&gt;3 -->
 <g id="edge9" class="edge"><title>9&#45;&gt;3</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M524.947,-290.684C520.566,-289.772 516.222,-288.872 512,-288 456.398,-276.52 394.088,-263.859 344.297,-253.792"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="344.686,-250.3 334.191,-251.749 343.299,-257.161 344.686,-250.3"/>
+<path fill="none" stroke="grey" stroke-width="2" d="M320.09,-431.697C326.923,-423.305 335.257,-413.07 342.756,-403.861"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="345.472,-406.069 349.072,-396.104 340.044,-401.649 345.472,-406.069"/>
 </g>
-<!-- 12 -->
-<g id="node13" class="node"><title>12</title>
-<path fill="none" stroke="#56d863" stroke-width="2" d="M870.5,-252C870.5,-252 781.5,-252 781.5,-252 775.5,-252 769.5,-246 769.5,-240 769.5,-240 769.5,-228 769.5,-228 769.5,-222 775.5,-216 781.5,-216 781.5,-216 870.5,-216 870.5,-216 876.5,-216 882.5,-222 882.5,-228 882.5,-228 882.5,-240 882.5,-240 882.5,-246 876.5,-252 870.5,-252"/>
-<text text-anchor="middle" x="826" y="-231.5" font-family="sans" font-size="10.00">pe_map_genome_star</text>
+<!-- 13 -->
+<g id="node14" class="node"><title>13</title>
+<path fill="none" stroke="#d8ac56" stroke-width="2" d="M120.5,-396C120.5,-396 17.5,-396 17.5,-396 11.5,-396 5.5,-390 5.5,-384 5.5,-384 5.5,-372 5.5,-372 5.5,-366 11.5,-360 17.5,-360 17.5,-360 120.5,-360 120.5,-360 126.5,-360 132.5,-366 132.5,-372 132.5,-372 132.5,-384 132.5,-384 132.5,-390 126.5,-396 120.5,-396"/>
+<text text-anchor="middle" x="69" y="-375.5" font-family="sans" font-size="10.00">pe_quantification_salmon</text>
 </g>
-<!-- 9&#45;&gt;12 -->
-<g id="edge27" class="edge"><title>9&#45;&gt;12</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M649.7,-287.966C682.945,-277.978 725.103,-265.312 759.857,-254.871"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="760.88,-258.219 769.45,-251.989 758.865,-251.515 760.88,-258.219"/>
+<!-- 9&#45;&gt;13 -->
+<g id="edge26" class="edge"><title>9&#45;&gt;13</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M248.326,-431.966C214.636,-422.015 171.947,-409.406 136.671,-398.987"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="137.514,-395.587 126.932,-396.111 135.531,-402.3 137.514,-395.587"/>
 </g>
-<!-- 16 -->
-<g id="node17" class="node"><title>16</title>
-<path fill="none" stroke="#566bd8" stroke-width="2" d="M596.5,-252C596.5,-252 493.5,-252 493.5,-252 487.5,-252 481.5,-246 481.5,-240 481.5,-240 481.5,-228 481.5,-228 481.5,-222 487.5,-216 493.5,-216 493.5,-216 596.5,-216 596.5,-216 602.5,-216 608.5,-222 608.5,-228 608.5,-228 608.5,-240 608.5,-240 608.5,-246 602.5,-252 596.5,-252"/>
-<text text-anchor="middle" x="545" y="-231.5" font-family="sans" font-size="10.00">pe_quantification_salmon</text>
+<!-- 15 -->
+<g id="node16" class="node"><title>15</title>
+<path fill="none" stroke="#56d8b1" stroke-width="2" d="M735.5,-396C735.5,-396 646.5,-396 646.5,-396 640.5,-396 634.5,-390 634.5,-384 634.5,-384 634.5,-372 634.5,-372 634.5,-366 640.5,-360 646.5,-360 646.5,-360 735.5,-360 735.5,-360 741.5,-360 747.5,-366 747.5,-372 747.5,-372 747.5,-384 747.5,-384 747.5,-390 741.5,-396 735.5,-396"/>
+<text text-anchor="middle" x="691" y="-375.5" font-family="sans" font-size="10.00">pe_map_genome_star</text>
 </g>
-<!-- 9&#45;&gt;16 -->
-<g id="edge33" class="edge"><title>9&#45;&gt;16</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M581.135,-287.697C575.497,-279.474 568.646,-269.483 562.431,-260.421"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="565.271,-258.372 556.729,-252.104 559.497,-262.331 565.271,-258.372"/>
+<!-- 9&#45;&gt;15 -->
+<g id="edge30" class="edge"><title>9&#45;&gt;15</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M374.384,-433.648C377.292,-433.075 380.173,-432.523 383,-432 489.057,-412.362 517.225,-417.104 623,-396 623.462,-395.908 623.926,-395.814 624.392,-395.72"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="625.273,-399.111 634.323,-393.602 623.813,-392.265 625.273,-399.111"/>
 </g>
 <!-- 10 -->
 <g id="node11" class="node"><title>10</title>
-<path fill="none" stroke="#d88556" stroke-width="2" d="M226,-324C226,-324 142,-324 142,-324 136,-324 130,-318 130,-312 130,-312 130,-300 130,-300 130,-294 136,-288 142,-288 142,-288 226,-288 226,-288 232,-288 238,-294 238,-300 238,-300 238,-312 238,-312 238,-318 232,-324 226,-324"/>
-<text text-anchor="middle" x="184" y="-303.5" font-family="sans" font-size="10.00">create_index_kallisto</text>
+<path fill="none" stroke="#b6d856" stroke-width="2" d="M488,-468C488,-468 404,-468 404,-468 398,-468 392,-462 392,-456 392,-456 392,-444 392,-444 392,-438 398,-432 404,-432 404,-432 488,-432 488,-432 494,-432 500,-438 500,-444 500,-444 500,-456 500,-456 500,-462 494,-468 488,-468"/>
+<text text-anchor="middle" x="446" y="-447.5" font-family="sans" font-size="10.00">create_index_kallisto</text>
 </g>
 <!-- 10&#45;&gt;3 -->
 <g id="edge10" class="edge"><title>10&#45;&gt;3</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M200.562,-287.697C208.675,-279.22 218.588,-268.864 227.471,-259.583"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="230.243,-261.749 234.629,-252.104 225.186,-256.908 230.243,-261.749"/>
+<path fill="none" stroke="grey" stroke-width="2" d="M425.483,-431.697C415.131,-422.965 402.414,-412.24 391.161,-402.75"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="393.182,-399.876 383.281,-396.104 388.669,-405.227 393.182,-399.876"/>
 </g>
 <!-- 10&#45;&gt;4 -->
-<g id="edge11" class="edge"><title>10&#45;&gt;4</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M157.336,-287.876C143.216,-278.808 125.689,-267.552 110.439,-257.759"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="112.073,-254.648 101.767,-252.19 108.29,-260.538 112.073,-254.648"/>
+<g id="edge12" class="edge"><title>10&#45;&gt;4</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M468.989,-431.697C480.814,-422.796 495.392,-411.823 508.179,-402.199"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="510.391,-404.915 516.276,-396.104 506.181,-399.322 510.391,-404.915"/>
 </g>
 <!-- 11 -->
 <g id="node12" class="node"><title>11</title>
-<path fill="none" stroke="#5682d8" stroke-width="2" d="M364,-324C364,-324 268,-324 268,-324 262,-324 256,-318 256,-312 256,-312 256,-300 256,-300 256,-294 262,-288 268,-288 268,-288 364,-288 364,-288 370,-288 376,-294 376,-300 376,-300 376,-312 376,-312 376,-318 370,-324 364,-324"/>
-<text text-anchor="middle" x="316" y="-303.5" font-family="sans" font-size="10.00">remove_polya_cutadapt</text>
+<path fill="none" stroke="#61d856" stroke-width="2" d="M629,-468C629,-468 533,-468 533,-468 527,-468 521,-462 521,-456 521,-456 521,-444 521,-444 521,-438 527,-432 533,-432 533,-432 629,-432 629,-432 635,-432 641,-438 641,-444 641,-444 641,-456 641,-456 641,-462 635,-468 629,-468"/>
+<text text-anchor="middle" x="581" y="-447.5" font-family="sans" font-size="10.00">remove_polya_cutadapt</text>
 </g>
 <!-- 11&#45;&gt;4 -->
-<g id="edge12" class="edge"><title>11&#45;&gt;4</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M257.353,-287.966C223.094,-278.015 179.684,-265.406 143.814,-254.987"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="144.489,-251.539 133.91,-252.111 142.537,-258.261 144.489,-251.539"/>
+<g id="edge11" class="edge"><title>11&#45;&gt;4</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M570.618,-431.697C565.735,-423.559 559.813,-413.689 554.421,-404.701"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="557.409,-402.879 549.263,-396.104 551.406,-406.48 557.409,-402.879"/>
 </g>
-<!-- 15 -->
-<g id="node16" class="node"><title>15</title>
-<path fill="none" stroke="#d86e56" stroke-width="2" d="M739.5,-252C739.5,-252 666.5,-252 666.5,-252 660.5,-252 654.5,-246 654.5,-240 654.5,-240 654.5,-228 654.5,-228 654.5,-222 660.5,-216 666.5,-216 666.5,-216 739.5,-216 739.5,-216 745.5,-216 751.5,-222 751.5,-228 751.5,-228 751.5,-240 751.5,-240 751.5,-246 745.5,-252 739.5,-252"/>
-<text text-anchor="middle" x="703" y="-231.5" font-family="sans" font-size="10.00">map_genome_star</text>
+<!-- 14 -->
+<g id="node15" class="node"><title>14</title>
+<path fill="none" stroke="#56d8c9" stroke-width="2" d="M249.5,-396C249.5,-396 162.5,-396 162.5,-396 156.5,-396 150.5,-390 150.5,-384 150.5,-384 150.5,-372 150.5,-372 150.5,-366 156.5,-360 162.5,-360 162.5,-360 249.5,-360 249.5,-360 255.5,-360 261.5,-366 261.5,-372 261.5,-372 261.5,-384 261.5,-384 261.5,-390 255.5,-396 249.5,-396"/>
+<text text-anchor="middle" x="206" y="-375.5" font-family="sans" font-size="10.00">quantification_salmon</text>
 </g>
-<!-- 11&#45;&gt;15 -->
-<g id="edge32" class="edge"><title>11&#45;&gt;15</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M376.141,-289.854C379.131,-289.204 382.097,-288.582 385,-288 487.311,-267.499 514.24,-270.121 617,-252 625.916,-250.428 635.331,-248.668 644.533,-246.894"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="645.255,-250.319 654.401,-244.97 643.916,-243.448 645.255,-250.319"/>
+<!-- 11&#45;&gt;14 -->
+<g id="edge27" class="edge"><title>11&#45;&gt;14</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M520.971,-434.439C516.927,-433.578 512.909,-432.756 509,-432 407.042,-412.286 377.502,-417.243 271.399,-395.95"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="272.076,-392.516 261.578,-393.949 270.678,-399.375 272.076,-392.516"/>
 </g>
 <!-- 17 -->
 <g id="node18" class="node"><title>17</title>
-<path fill="none" stroke="#56d8d0" stroke-width="2" d="M451.5,-252C451.5,-252 364.5,-252 364.5,-252 358.5,-252 352.5,-246 352.5,-240 352.5,-240 352.5,-228 352.5,-228 352.5,-222 358.5,-216 364.5,-216 364.5,-216 451.5,-216 451.5,-216 457.5,-216 463.5,-222 463.5,-228 463.5,-228 463.5,-240 463.5,-240 463.5,-246 457.5,-252 451.5,-252"/>
-<text text-anchor="middle" x="408" y="-231.5" font-family="sans" font-size="10.00">quantification_salmon</text>
+<path fill="none" stroke="#d8d356" stroke-width="2" d="M850.5,-396C850.5,-396 777.5,-396 777.5,-396 771.5,-396 765.5,-390 765.5,-384 765.5,-384 765.5,-372 765.5,-372 765.5,-366 771.5,-360 777.5,-360 777.5,-360 850.5,-360 850.5,-360 856.5,-360 862.5,-366 862.5,-372 862.5,-372 862.5,-384 862.5,-384 862.5,-390 856.5,-396 850.5,-396"/>
+<text text-anchor="middle" x="814" y="-375.5" font-family="sans" font-size="10.00">map_genome_star</text>
 </g>
 <!-- 11&#45;&gt;17 -->
-<g id="edge36" class="edge"><title>11&#45;&gt;17</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M338.742,-287.697C350.44,-278.796 364.861,-267.823 377.51,-258.199"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="379.681,-260.945 385.52,-252.104 375.442,-255.374 379.681,-260.945"/>
+<g id="edge33" class="edge"><title>11&#45;&gt;17</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M637.7,-431.966C673.407,-421.238 719.397,-407.421 755.452,-396.59"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="756.771,-399.848 765.341,-393.619 754.756,-393.144 756.771,-399.848"/>
+</g>
+<!-- 12 -->
+<g id="node13" class="node"><title>12</title>
+<path fill="none" stroke="#d8bc56" stroke-width="2" d="M522,-180C522,-180 446,-180 446,-180 440,-180 434,-174 434,-168 434,-168 434,-156 434,-156 434,-150 440,-144 446,-144 446,-144 522,-144 522,-144 528,-144 534,-150 534,-156 534,-156 534,-168 534,-168 534,-174 528,-180 522,-180"/>
+<text text-anchor="middle" x="484" y="-159.5" font-family="sans" font-size="10.00">merge_TIN_scores</text>
 </g>
 <!-- 12&#45;&gt;5 -->
 <g id="edge13" class="edge"><title>12&#45;&gt;5</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M882.701,-227.711C942.874,-220.787 1032.12,-206.314 1053,-180 1097.93,-123.369 978.505,-102.581 898.196,-95.0901"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="898.392,-91.5938 888.123,-94.2002 897.776,-98.5667 898.392,-91.5938"/>
+<path fill="none" stroke="grey" stroke-width="2" d="M479.798,-143.697C477.904,-135.898 475.623,-126.509 473.516,-117.829"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="476.915,-116.996 471.154,-108.104 470.113,-118.648 476.915,-116.996"/>
 </g>
-<!-- 12&#45;&gt;8 -->
-<g id="edge21" class="edge"><title>12&#45;&gt;8</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M828.376,-215.846C830.096,-196.225 829.723,-164.213 813,-144 784.703,-109.797 733.1,-97.6237 697.71,-93.3162"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="698.055,-89.8333 687.741,-92.257 697.316,-96.7942 698.055,-89.8333"/>
+<!-- 13&#45;&gt;6 -->
+<g id="edge15" class="edge"><title>13&#45;&gt;6</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M68.7528,-359.697C68.6426,-351.983 68.5102,-342.712 68.3873,-334.112"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="71.8869,-334.053 68.2443,-324.104 64.8876,-334.153 71.8869,-334.053"/>
 </g>
-<!-- 13 -->
-<g id="node14" class="node"><title>13</title>
-<path fill="none" stroke="#569ad8" stroke-width="2" d="M792,-180C792,-180 642,-180 642,-180 636,-180 630,-174 630,-168 630,-168 630,-156 630,-156 630,-150 636,-144 642,-144 642,-144 792,-144 792,-144 798,-144 804,-150 804,-156 804,-156 804,-168 804,-168 804,-174 798,-180 792,-180"/>
-<text text-anchor="middle" x="717" y="-159.5" font-family="sans" font-size="10.00">index_genomic_alignment_samtools</text>
+<!-- 13&#45;&gt;7 -->
+<g id="edge17" class="edge"><title>13&#45;&gt;7</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M108.874,-359.876C131.157,-350.307 159.115,-338.3 182.756,-328.148"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="184.448,-331.23 192.255,-324.068 181.686,-324.798 184.448,-331.23"/>
 </g>
-<!-- 12&#45;&gt;13 -->
-<g id="edge29" class="edge"><title>12&#45;&gt;13</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M799.336,-215.876C785.216,-206.808 767.689,-195.552 752.439,-185.759"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="754.073,-182.648 743.767,-180.19 750.29,-188.538 754.073,-182.648"/>
+<!-- 14&#45;&gt;6 -->
+<g id="edge14" class="edge"><title>14&#45;&gt;6</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M172.241,-359.876C153.78,-350.512 130.718,-338.814 110.983,-328.803"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="112.39,-325.592 101.888,-324.19 109.223,-331.835 112.39,-325.592"/>
 </g>
-<!-- 13&#45;&gt;5 -->
-<g id="edge15" class="edge"><title>13&#45;&gt;5</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M745.132,-143.876C760.168,-134.724 778.867,-123.342 795.06,-113.485"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="797.038,-116.379 803.76,-108.19 793.398,-110.4 797.038,-116.379"/>
+<!-- 14&#45;&gt;7 -->
+<g id="edge16" class="edge"><title>14&#45;&gt;7</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M212.427,-359.697C215.355,-351.813 218.887,-342.304 222.14,-333.546"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="225.446,-334.697 225.647,-324.104 218.884,-332.26 225.446,-334.697"/>
 </g>
-<!-- 13&#45;&gt;8 -->
-<g id="edge23" class="edge"><title>13&#45;&gt;8</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M702.91,-143.697C696.077,-135.305 687.743,-125.07 680.244,-115.861"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="682.956,-113.649 673.928,-108.104 677.528,-118.069 682.956,-113.649"/>
-</g>
-<!-- 14 -->
-<g id="node15" class="node"><title>14</title>
-<path fill="none" stroke="#d89c56" stroke-width="2" d="M1031.5,-180C1031.5,-180 910.5,-180 910.5,-180 904.5,-180 898.5,-174 898.5,-168 898.5,-168 898.5,-156 898.5,-156 898.5,-150 904.5,-144 910.5,-144 910.5,-144 1031.5,-144 1031.5,-144 1037.5,-144 1043.5,-150 1043.5,-156 1043.5,-156 1043.5,-168 1043.5,-168 1043.5,-174 1037.5,-180 1031.5,-180"/>
-<text text-anchor="middle" x="971" y="-159.5" font-family="sans" font-size="10.00">extract_transcripts_as_bed12</text>
+<!-- 15&#45;&gt;8 -->
+<g id="edge20" class="edge"><title>15&#45;&gt;8</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M745.82,-359.961C762.658,-351.866 779.295,-340.283 789,-324 801.284,-303.391 787.883,-278.213 773.544,-259.902"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="776.066,-257.461 766.979,-252.014 770.686,-261.939 776.066,-257.461"/>
 </g>
-<!-- 14&#45;&gt;5 -->
-<g id="edge16" class="edge"><title>14&#45;&gt;5</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M936.997,-143.876C918.402,-134.512 895.173,-122.814 875.294,-112.803"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="876.64,-109.562 866.134,-108.19 873.491,-115.814 876.64,-109.562"/>
+<!-- 16 -->
+<g id="node17" class="node"><title>16</title>
+<path fill="none" stroke="#56d88a" stroke-width="2" d="M768,-324C768,-324 618,-324 618,-324 612,-324 606,-318 606,-312 606,-312 606,-300 606,-300 606,-294 612,-288 618,-288 618,-288 768,-288 768,-288 774,-288 780,-294 780,-300 780,-300 780,-312 780,-312 780,-318 774,-324 768,-324"/>
+<text text-anchor="middle" x="693" y="-303.5" font-family="sans" font-size="10.00">index_genomic_alignment_samtools</text>
 </g>
-<!-- 15&#45;&gt;5 -->
-<g id="edge14" class="edge"><title>15&#45;&gt;5</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M748.156,-215.971C774.497,-205.165 804.224,-191.167 813,-180 826.692,-162.577 831.084,-137.531 832.257,-118.444"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="835.761,-118.387 832.619,-108.269 828.766,-118.138 835.761,-118.387"/>
+<!-- 15&#45;&gt;16 -->
+<g id="edge32" class="edge"><title>15&#45;&gt;16</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M691.494,-359.697C691.715,-351.983 691.98,-342.712 692.225,-334.112"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="695.724,-334.2 692.511,-324.104 688.727,-334 695.724,-334.2"/>
 </g>
-<!-- 15&#45;&gt;8 -->
-<g id="edge22" class="edge"><title>15&#45;&gt;8</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M660.382,-215.989C645.126,-207.58 629.591,-195.781 621,-180 609.599,-159.056 622.679,-134.107 636.68,-115.961"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="639.458,-118.093 643.094,-108.141 634.046,-113.654 639.458,-118.093"/>
-</g>
-<!-- 15&#45;&gt;13 -->
-<g id="edge30" class="edge"><title>15&#45;&gt;13</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M706.461,-215.697C708.003,-207.983 709.858,-198.712 711.578,-190.112"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="715.05,-190.597 713.579,-180.104 708.186,-189.224 715.05,-190.597"/>
-</g>
-<!-- 16&#45;&gt;6 -->
-<g id="edge17" class="edge"><title>16&#45;&gt;6</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M535.36,-215.697C530.873,-207.644 525.441,-197.894 520.476,-188.982"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="523.454,-187.137 515.53,-180.104 517.339,-190.544 523.454,-187.137"/>
-</g>
-<!-- 16&#45;&gt;7 -->
-<g id="edge19" class="edge"><title>16&#45;&gt;7</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M495.6,-215.966C467.113,-206.142 431.114,-193.729 401.129,-183.389"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="402.216,-180.062 391.621,-180.111 399.934,-186.68 402.216,-180.062"/>
-</g>
-<!-- 17&#45;&gt;6 -->
-<g id="edge18" class="edge"><title>17&#45;&gt;6</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M431.973,-215.876C444.55,-206.893 460.132,-195.763 473.752,-186.034"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="475.831,-188.85 481.934,-180.19 471.763,-183.154 475.831,-188.85"/>
-</g>
-<!-- 17&#45;&gt;7 -->
-<g id="edge20" class="edge"><title>17&#45;&gt;7</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M391.685,-215.697C383.693,-207.22 373.928,-196.864 365.178,-187.583"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="367.534,-184.979 358.127,-180.104 362.441,-189.781 367.534,-184.979"/>
+<!-- 21 -->
+<g id="node22" class="node"><title>21</title>
+<path fill="none" stroke="#56d8a2" stroke-width="2" d="M559,-252C559,-252 471,-252 471,-252 465,-252 459,-246 459,-240 459,-240 459,-228 459,-228 459,-222 465,-216 471,-216 471,-216 559,-216 559,-216 565,-216 571,-222 571,-228 571,-228 571,-240 571,-240 571,-246 565,-252 559,-252"/>
+<text text-anchor="middle" x="515" y="-231.5" font-family="sans" font-size="10.00">calculate_TIN_scores</text>
+</g>
+<!-- 15&#45;&gt;21 -->
+<g id="edge38" class="edge"><title>15&#45;&gt;21</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M634.288,-362.566C630.473,-361.674 626.684,-360.811 623,-360 581.244,-350.811 461.258,-356.94 434,-324 423.8,-311.673 426.39,-302.074 434,-288 440.818,-275.391 452.085,-265.3 464.079,-257.45"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="466.141,-260.294 472.888,-252.126 462.52,-254.303 466.141,-260.294"/>
+</g>
+<!-- 16&#45;&gt;8 -->
+<g id="edge18" class="edge"><title>16&#45;&gt;8</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M707.09,-287.697C713.923,-279.305 722.257,-269.07 729.756,-259.861"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="732.472,-262.069 736.072,-252.104 727.044,-257.649 732.472,-262.069"/>
+</g>
+<!-- 16&#45;&gt;21 -->
+<g id="edge35" class="edge"><title>16&#45;&gt;21</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M649.456,-287.876C624.798,-278.179 593.777,-265.98 567.746,-255.743"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="568.989,-252.471 558.402,-252.068 566.428,-258.985 568.989,-252.471"/>
+</g>
+<!-- 17&#45;&gt;8 -->
+<g id="edge19" class="edge"><title>17&#45;&gt;8</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M833.772,-359.802C852.309,-341.524 875.081,-312.007 860,-288 844.242,-262.915 812.909,-249.424 787.701,-242.343"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="788.244,-238.869 777.688,-239.768 786.501,-245.649 788.244,-238.869"/>
+</g>
+<!-- 17&#45;&gt;16 -->
+<g id="edge31" class="edge"><title>17&#45;&gt;16</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M784.4,-359.876C768.433,-350.639 748.54,-339.131 731.394,-329.212"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="733.122,-326.168 722.714,-324.19 729.617,-332.227 733.122,-326.168"/>
+</g>
+<!-- 17&#45;&gt;21 -->
+<g id="edge37" class="edge"><title>17&#45;&gt;21</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M814.228,-359.872C813.512,-339.662 809.074,-306.478 789,-288 759.355,-260.712 652.576,-246.511 581.402,-239.909"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="581.446,-236.399 571.173,-238.99 580.819,-243.371 581.446,-236.399"/>
 </g>
 <!-- 18 -->
 <g id="node19" class="node"><title>18</title>
-<path fill="none" stroke="#d6d856" stroke-width="2" d="M658,-396C658,-396 532,-396 532,-396 526,-396 520,-390 520,-384 520,-384 520,-372 520,-372 520,-366 526,-360 532,-360 532,-360 658,-360 658,-360 664,-360 670,-366 670,-372 670,-372 670,-384 670,-384 670,-390 664,-396 658,-396"/>
-<text text-anchor="middle" x="595" y="-375.5" font-family="sans" font-size="10.00">pe_remove_adapters_cutadapt</text>
+<path fill="none" stroke="#d87d56" stroke-width="2" d="M358,-540C358,-540 232,-540 232,-540 226,-540 220,-534 220,-528 220,-528 220,-516 220,-516 220,-510 226,-504 232,-504 232,-504 358,-504 358,-504 364,-504 370,-510 370,-516 370,-516 370,-528 370,-528 370,-534 364,-540 358,-540"/>
+<text text-anchor="middle" x="295" y="-519.5" font-family="sans" font-size="10.00">pe_remove_adapters_cutadapt</text>
 </g>
 <!-- 18&#45;&gt;9 -->
-<g id="edge24" class="edge"><title>18&#45;&gt;9</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M594.506,-359.697C594.285,-351.983 594.02,-342.712 593.775,-334.112"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="597.273,-334 593.489,-324.104 590.276,-334.2 597.273,-334"/>
+<g id="edge21" class="edge"><title>18&#45;&gt;9</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M297.719,-503.697C298.931,-495.983 300.388,-486.712 301.739,-478.112"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="305.217,-478.526 303.312,-468.104 298.302,-477.44 305.217,-478.526"/>
 </g>
 <!-- 19 -->
 <g id="node20" class="node"><title>19</title>
-<path fill="none" stroke="#d8c356" stroke-width="2" d="M490.5,-396C490.5,-396 403.5,-396 403.5,-396 397.5,-396 391.5,-390 391.5,-384 391.5,-384 391.5,-372 391.5,-372 391.5,-366 397.5,-360 403.5,-360 403.5,-360 490.5,-360 490.5,-360 496.5,-360 502.5,-366 502.5,-372 502.5,-372 502.5,-384 502.5,-384 502.5,-390 496.5,-396 490.5,-396"/>
-<text text-anchor="middle" x="447" y="-375.5" font-family="sans" font-size="10.00">extract_transcriptome</text>
+<path fill="none" stroke="#56d0d8" stroke-width="2" d="M487.5,-540C487.5,-540 400.5,-540 400.5,-540 394.5,-540 388.5,-534 388.5,-528 388.5,-528 388.5,-516 388.5,-516 388.5,-510 394.5,-504 400.5,-504 400.5,-504 487.5,-504 487.5,-504 493.5,-504 499.5,-510 499.5,-516 499.5,-516 499.5,-528 499.5,-528 499.5,-534 493.5,-540 487.5,-540"/>
+<text text-anchor="middle" x="444" y="-519.5" font-family="sans" font-size="10.00">extract_transcriptome</text>
 </g>
 <!-- 19&#45;&gt;10 -->
-<g id="edge25" class="edge"><title>19&#45;&gt;10</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M391.375,-362.331C353.51,-352.33 301.991,-338.689 248.035,-324.272"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="248.857,-320.869 238.292,-321.667 247.049,-327.631 248.857,-320.869"/>
+<g id="edge22" class="edge"><title>19&#45;&gt;10</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M444.494,-503.697C444.715,-495.983 444.98,-486.712 445.225,-478.112"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="448.724,-478.2 445.511,-468.104 441.727,-478 448.724,-478.2"/>
 </g>
 <!-- 22 -->
 <g id="node23" class="node"><title>22</title>
-<path fill="none" stroke="#61d856" stroke-width="2" d="M491.5,-324C491.5,-324 406.5,-324 406.5,-324 400.5,-324 394.5,-318 394.5,-312 394.5,-312 394.5,-300 394.5,-300 394.5,-294 400.5,-288 406.5,-288 406.5,-288 491.5,-288 491.5,-288 497.5,-288 503.5,-294 503.5,-300 503.5,-300 503.5,-312 503.5,-312 503.5,-318 497.5,-324 491.5,-324"/>
-<text text-anchor="middle" x="449" y="-303.5" font-family="sans" font-size="10.00">create_index_salmon</text>
+<path fill="none" stroke="#5692d8" stroke-width="2" d="M207.5,-468C207.5,-468 122.5,-468 122.5,-468 116.5,-468 110.5,-462 110.5,-456 110.5,-456 110.5,-444 110.5,-444 110.5,-438 116.5,-432 122.5,-432 122.5,-432 207.5,-432 207.5,-432 213.5,-432 219.5,-438 219.5,-444 219.5,-444 219.5,-456 219.5,-456 219.5,-462 213.5,-468 207.5,-468"/>
+<text text-anchor="middle" x="165" y="-447.5" font-family="sans" font-size="10.00">create_index_salmon</text>
 </g>
 <!-- 19&#45;&gt;22 -->
-<g id="edge37" class="edge"><title>19&#45;&gt;22</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M447.494,-359.697C447.715,-351.983 447.98,-342.712 448.225,-334.112"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="451.724,-334.2 448.511,-324.104 444.727,-334 451.724,-334.2"/>
+<g id="edge39" class="edge"><title>19&#45;&gt;22</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M388.35,-506.366C385.188,-505.559 382.055,-504.766 379,-504 315.486,-488.074 297.099,-485.057 229.644,-468.13"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="230.342,-464.697 219.79,-465.646 228.632,-471.484 230.342,-464.697"/>
 </g>
 <!-- 20 -->
 <g id="node21" class="node"><title>20</title>
-<path fill="none" stroke="#bed856" stroke-width="2" d="M361,-396C361,-396 251,-396 251,-396 245,-396 239,-390 239,-384 239,-384 239,-372 239,-372 239,-366 245,-360 251,-360 251,-360 361,-360 361,-360 367,-360 373,-366 373,-372 373,-372 373,-384 373,-384 373,-390 367,-396 361,-396"/>
-<text text-anchor="middle" x="306" y="-375.5" font-family="sans" font-size="10.00">remove_adapters_cutadapt</text>
+<path fill="none" stroke="#78d856" stroke-width="2" d="M640,-540C640,-540 530,-540 530,-540 524,-540 518,-534 518,-528 518,-528 518,-516 518,-516 518,-510 524,-504 530,-504 530,-504 640,-504 640,-504 646,-504 652,-510 652,-516 652,-516 652,-528 652,-528 652,-534 646,-540 640,-540"/>
+<text text-anchor="middle" x="585" y="-519.5" font-family="sans" font-size="10.00">remove_adapters_cutadapt</text>
 </g>
 <!-- 20&#45;&gt;11 -->
-<g id="edge26" class="edge"><title>20&#45;&gt;11</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M308.472,-359.697C309.574,-351.983 310.898,-342.712 312.127,-334.112"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="315.607,-334.499 313.557,-324.104 308.677,-333.509 315.607,-334.499"/>
-</g>
-<!-- 21 -->
-<g id="node22" class="node"><title>21</title>
-<path fill="none" stroke="#78d856" stroke-width="2" d="M819,-324C819,-324 749,-324 749,-324 743,-324 737,-318 737,-312 737,-312 737,-300 737,-300 737,-294 743,-288 749,-288 749,-288 819,-288 819,-288 825,-288 831,-294 831,-300 831,-300 831,-312 831,-312 831,-318 825,-324 819,-324"/>
-<text text-anchor="middle" x="784" y="-303.5" font-family="sans" font-size="10.00">create_index_star</text>
+<g id="edge23" class="edge"><title>20&#45;&gt;11</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M584.011,-503.697C583.57,-495.983 583.041,-486.712 582.549,-478.112"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="586.042,-477.888 581.977,-468.104 579.054,-478.288 586.042,-477.888"/>
 </g>
 <!-- 21&#45;&gt;12 -->
-<g id="edge28" class="edge"><title>21&#45;&gt;12</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M794.382,-287.697C799.265,-279.559 805.187,-269.689 810.579,-260.701"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="813.594,-262.48 815.737,-252.104 807.591,-258.879 813.594,-262.48"/>
-</g>
-<!-- 21&#45;&gt;15 -->
-<g id="edge31" class="edge"><title>21&#45;&gt;15</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M763.978,-287.697C753.874,-278.965 741.464,-268.24 730.482,-258.75"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="732.647,-255.995 722.792,-252.104 728.07,-261.291 732.647,-255.995"/>
-</g>
-<!-- 22&#45;&gt;16 -->
-<g id="edge34" class="edge"><title>22&#45;&gt;16</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M472.73,-287.697C484.937,-278.796 499.985,-267.823 513.184,-258.199"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="515.525,-260.824 521.543,-252.104 511.4,-255.168 515.525,-260.824"/>
-</g>
-<!-- 22&#45;&gt;17 -->
-<g id="edge35" class="edge"><title>22&#45;&gt;17</title>
-<path fill="none" stroke="grey" stroke-width="2" d="M438.865,-287.697C434.148,-279.644 428.438,-269.894 423.218,-260.982"/>
-<polygon fill="grey" stroke="grey" stroke-width="2" points="426.092,-258.964 418.018,-252.104 420.052,-262.502 426.092,-258.964"/>
+<g id="edge24" class="edge"><title>21&#45;&gt;12</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M507.337,-215.697C503.808,-207.728 499.544,-198.1 495.631,-189.264"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="498.824,-187.831 491.575,-180.104 492.424,-190.665 498.824,-187.831"/>
+</g>
+<!-- 22&#45;&gt;13 -->
+<g id="edge25" class="edge"><title>22&#45;&gt;13</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M141.27,-431.697C129.063,-422.796 114.015,-411.823 100.816,-402.199"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="102.6,-399.168 92.4574,-396.104 98.4753,-404.824 102.6,-399.168"/>
+</g>
+<!-- 22&#45;&gt;14 -->
+<g id="edge28" class="edge"><title>22&#45;&gt;14</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M175.135,-431.697C179.852,-423.644 185.562,-413.894 190.782,-404.982"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="193.948,-406.502 195.982,-396.104 187.908,-402.964 193.948,-406.502"/>
+</g>
+<!-- 23 -->
+<g id="node24" class="node"><title>23</title>
+<path fill="none" stroke="#d85656" stroke-width="2" d="M787,-468C787,-468 717,-468 717,-468 711,-468 705,-462 705,-456 705,-456 705,-444 705,-444 705,-438 711,-432 717,-432 717,-432 787,-432 787,-432 793,-432 799,-438 799,-444 799,-444 799,-456 799,-456 799,-462 793,-468 787,-468"/>
+<text text-anchor="middle" x="752" y="-447.5" font-family="sans" font-size="10.00">create_index_star</text>
+</g>
+<!-- 23&#45;&gt;15 -->
+<g id="edge29" class="edge"><title>23&#45;&gt;15</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M736.921,-431.697C729.608,-423.305 720.69,-413.07 712.665,-403.861"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="715.114,-401.344 705.905,-396.104 709.836,-405.943 715.114,-401.344"/>
+</g>
+<!-- 23&#45;&gt;17 -->
+<g id="edge34" class="edge"><title>23&#45;&gt;17</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M767.326,-431.697C774.759,-423.305 783.823,-413.07 791.98,-403.861"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="794.84,-405.911 798.85,-396.104 789.6,-401.27 794.84,-405.911"/>
+</g>
+<!-- 24 -->
+<g id="node25" class="node"><title>24</title>
+<path fill="none" stroke="#566bd8" stroke-width="2" d="M575.5,-324C575.5,-324 454.5,-324 454.5,-324 448.5,-324 442.5,-318 442.5,-312 442.5,-312 442.5,-300 442.5,-300 442.5,-294 448.5,-288 454.5,-288 454.5,-288 575.5,-288 575.5,-288 581.5,-288 587.5,-294 587.5,-300 587.5,-300 587.5,-312 587.5,-312 587.5,-318 581.5,-324 575.5,-324"/>
+<text text-anchor="middle" x="515" y="-303.5" font-family="sans" font-size="10.00">extract_transcripts_as_bed12</text>
+</g>
+<!-- 24&#45;&gt;21 -->
+<g id="edge36" class="edge"><title>24&#45;&gt;21</title>
+<path fill="none" stroke="grey" stroke-width="2" d="M515,-287.697C515,-279.983 515,-270.712 515,-262.112"/>
+<polygon fill="grey" stroke="grey" stroke-width="2" points="518.5,-262.104 515,-252.104 511.5,-262.104 518.5,-262.104"/>
 </g>
 </g>
 </svg>
diff --git a/tests/input_files/cluster.json b/tests/input_files/cluster.json
index f045618..46bc56c 100644
--- a/tests/input_files/cluster.json
+++ b/tests/input_files/cluster.json
@@ -43,5 +43,17 @@
     "time": "06:00:00",
     "threads":"8",
     "mem":"32G"
+  },
+  "merge_TIN_scores":
+  {
+    "time": "00:05:00",
+    "threads":"1",
+    "mem":"4G"
+  },
+  "plot_TIN_scores":
+  {
+    "time": "00:05:00",
+    "threads":"1",
+    "mem":"4G"
   }
 }
-- 
GitLab