Commit 9c63ef86 authored by LANORE Vincent's avatar LANORE Vincent
Browse files

Added basic infrastructure for param exploration

parent 742207bf
......@@ -273,3 +273,36 @@ let benchmark2 d =
pcoc d ;
tdg09 d ;
]
(* param exploration for SMBE paper *)
type branch_factor_t = float
let branch_factor_range = [ 1.; 2.; 3.; 4.; 5. ]
type gBGC_t = Global of float | Convergent of float * float
let gBGC_range =
let range = [ 0.; 2.; 4.; 8.; 16. ] in
List.concat [
(* List.map ~f:(fun x -> Global x) range ; *)
List.map ~f:(fun x -> Convergent (0., x)) range ;
]
type param_t = branch_factor_t * gBGC_t
let explore_params ~(f: param_t -> _) =
List.map branch_factor_range ~f:(fun (bf:branch_factor_t) ->
List.map gBGC_range ~f:(fun (gbgc:gBGC_t) -> (bf, gbgc, f (bf, gbgc)))
) |> List.concat
let simu_of_param ?n_h0:(n_h0=50) (p: param_t) =
let bf, gbgc = p in
convdet_simulation
~tree:(`NHX "example/trees_analyses/C4AmaranthaceaePolyroot.nhx")
~profiles:"example/aa_fitness/263SelectedProfiles.tsv"
~branch_factor:bf
~gBGC:(match gbgc with
| Convergent (a,c) -> (a, c)
| Global g -> (g, g))
~ne_s:(4., 4.)
~n_ha:0
~n_h0
()
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