Commit d79f5bbb authored by Louis Duchemin's avatar Louis Duchemin

RER converge autoformat

parent ccba87bb
......@@ -16,14 +16,18 @@ let gene_tree_file gene_trees =
fun dest ->
let load_tree newick_path =
In_channel.read_all newick_path
|> String.filter ~f:(function '\n' | '\t' -> false | _ -> true) in
|> String.filter ~f:(function '\n' | '\t' -> false | _ -> true)
in
let newick_trees =
[%eval Workflow.path_list newicks] |> List.map ~f:load_tree in
[%eval Workflow.path_list newicks] |> List.map ~f:load_tree
in
let lines =
List.map2_exn
~f:(fun gene tree -> String.concat ~sep:"\t" [gene; tree])
gene_ids newick_trees in
Out_channel.write_lines dest lines] in
~f:(fun gene tree -> String.concat ~sep:"\t" [ gene; tree ])
gene_ids newick_trees
in
Out_channel.write_lines dest lines]
in
Workflow.path_plugin ~descr:"rer_converge.gene_tree_file" f
let template_transform t =
......@@ -108,5 +112,5 @@ write_tsv({{dest}}, res)
let rer_converge ?max_read ?(transform = `sqrt) ?(weighted = true)
?(scale = true) ?(continuous = false) ~gene_tree_set ~phenotype =
Bistro_utils.R_script.workflow ~descr:"rer_converge"
(script ?max_read ~transform ~weighted ~scale ~continuous ~gene_tree_set
~phenotype)
(script ?max_read ~transform ~weighted ~scale ~continuous
~gene_tree_set ~phenotype)
......@@ -7,11 +7,11 @@ val phenotypes_of_convergent_species :
val gene_tree_file : (string * newick file) list -> tsv file
val rer_converge :
?max_read:int
-> ?transform:[`none | `sqrt | `log]
-> ?weighted:bool
-> ?scale:bool
-> ?continuous:bool
-> gene_tree_set:tsv file
-> phenotype:tsv file
-> tsv file
?max_read:int ->
?transform:[ `none | `sqrt | `log ] ->
?weighted:bool ->
?scale:bool ->
?continuous:bool ->
gene_tree_set:tsv file ->
phenotype:tsv file ->
tsv file
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