Commit 4347aa02 by MARIJON Pierre

support color functionality of path_in_gfa

parent 901b343b
......@@ -70,3 +70,15 @@ rule create_fake_canu_contig_on_canu_paf_gfa:
shell:
"ln -s {input.paf} {output.link}"
rule search_path:
input:
search = "{prefix}_{name}_extremity_search.csv",
canu2realname = canu_bog_readname,
read2contig = canu_read2tig,
contig2color = canu_contig_on_canu_paf + '.legend.csv',
canu_paf = canu_paf_gfa_rename
output:
result = "{prefix}_{name}_extremity_result.csv"
threads: 99
run:
shell(" ".join(["path_in_gfa", input.canu_paf, input.search, output.result, canu_search_path_prefix, "-t", str(threads), "-n", input.canu2realname, "-r", input.read2contig, "-c", input.contig2color]))
......@@ -30,3 +30,22 @@ rule create_fake_canu_contig_on_canu_paf_gfa:
shell:
"ln -s {input.paf} {output.link}"
rule search_path:
input:
search = "{prefix}_{name}_extremity_search.csv",
canu2realname = canu_bog_readname,
read2contig = canu_read2tig,
contig2color = canu_contig_on_minimap_paf + '.legend.csv',
canu_paf = canu_paf_gfa_rename,
minimap_paf = minimap_paf + ".gfa"
output:
result = "{prefix}_{name}_extremity_result.csv"
threads: 99
run:
if wildcards.name == "canu":
shell(" ".join(["path_in_gfa", input.canu_paf, input.search, output.result, canu_search_path_prefix, "-t", str(threads), "-n", input.canu2realname, "-r", input.read2contig, "-c", input.contig2color]))
else:
shell(" ".join(["path_in_gfa", input.minimap_paf, input.search, output.result, minimap_search_path_prefix, "-t", str(threads), "-n", input.canu2realname, "-r", input.read2contig, "-c", input.contig2color]))
......@@ -25,7 +25,8 @@ For each free read contig extremity, we search path to other free read contig ex
<li>If case have no button we didn't run path search (same contig read)</li>
<li>If text of button is False we didn't find path between reads but me generate a little dfs (max deep is 10) for each</li>
<li>If text of button is True we find a path between reads and perform a dfs for each (max deep is <code>shortest path length * 2</code>) and make union of this graph</li>
<li>Target reads are colored in red</li>
<li>Target reads have arrow shape</li>
<li>Node color correspond to graph projection color</li>
</ul>
</div>
......
......@@ -211,7 +211,8 @@ For each free read contig extremity, we search path to other free read contig ex
<li>If case have no button we didn't run path search (same contig read)</li>
<li>If text of button is False we didn't find path between reads but me generate a little dfs (max deep is 10) for each</li>
<li>If text of button is True we find a path between reads and perform a dfs for each (max deep is <code>shortest path length * 2</code>) and make union of this graph</li>
<li>Target reads are colored in red</li>
<li>Target reads have arrow shape</li>
<li>Node color correspond to graph projection color</li>
</ul>
</div>
......
......@@ -36,20 +36,6 @@ rule bandage_colo:
shell:
config['bandage']['bin'] + " image {input.gfa} {output.png} --colors {input.csv} 2> /dev/null"
rule search_path:
input:
search = "{prefix}_{name}_extremity_search.csv",
canu_paf = canu_paf_gfa_rename
#minimap_paf = minimap_paf + ".gfa"
output:
result = "{prefix}_{name}_extremity_result.csv"
threads: 8
run:
if wildcards.name == "canu":
shell(" ".join(["path_in_gfa", input.canu_paf, input.search, output.result, canu_search_path_prefix, "-t", str(threads)]))
else:
shell(" ".join(["path_in_gfa", minimap_paf + ".gfa", input.search, output.result, minimap_search_path_prefix, "-t", str(threads)]))
rule generate_search_path:
output:
search = "{prefix}_{name}_extremity_search.csv"
......
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