Commit 63e14e8c authored by Philippe Veber's avatar Philippe Veber
Browse files

Detection_pipeline: added failsafe version of tdg09

parent ddd66484
......@@ -26,6 +26,7 @@ module type S = sig
val multinomial_asymptotic_lrt : query -> text file
val multinomial_asymptotic_sparse : query -> text file
val tdg09 : query -> text file
val failsafe_tdg09 : query -> text file
val pcoc : ?gamma:bool -> ?ncat:int -> query -> text file
val pcoc_v2 :
?gamma:bool ->
......@@ -105,6 +106,18 @@ module Make(Q : Query) = struct
()
|> Tamuri.results
let%pworkflow mock_tdg09 d =
match Biotk.Fasta.from_file [%path amino_acid_alignment d] with
| Ok (_, item :: _) ->
let open Core_kernel in
let n = String.length item.sequence in
"Sites Tdg09_1MinusFDR Tdg09_1MinusLRT Tdg09_prob_post"
:: List.init n ~f:(fun i -> sprintf "%d\t0.0\t0.0\tNA" (i + 1))
|> Out_channel.write_lines [%dest]
| _ -> failwith "couldn't read an item in fasta"
let failsafe_tdg09 d = Workflow.trywith (tdg09 d) (mock_tdg09 d)
let diffseltree d =
Tree_dataset.prepare_diffsel_tree (tree ~branch_length_unit:`Amino_acid d)
......
......@@ -26,6 +26,7 @@ module type S = sig
val multinomial_asymptotic_lrt : query -> text file
val multinomial_asymptotic_sparse : query -> text file
val tdg09 : query -> text file
val failsafe_tdg09 : query -> text file
val pcoc : ?gamma:bool -> ?ncat:int -> query -> text file
val pcoc_v2 :
?gamma:bool ->
......
......@@ -535,7 +535,7 @@ let site_ranking ?subset ~meth ~convergent_species db =
| `multinomial_asymptotic_lrt ->
multinomial_asymptotic_lrt, "1MinusLRT"
| `tdg09 ->
tdg09, "Tdg09_1MinusFDR"
failsafe_tdg09, "Tdg09_1MinusFDR"
in
let queries =
alignments_of_db db
......
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