From 0a71ee956b7541893a91e5101d76acf743457311 Mon Sep 17 00:00:00 2001 From: EvaLiyt Date: Tue, 19 Nov 2024 16:25:18 +1300 Subject: [PATCH] add comments for CalibratedYuleToBeast #168 --- .../tobeast/generators/CalibratedYuleToBeast.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lphybeast/src/main/java/lphybeast/tobeast/generators/CalibratedYuleToBeast.java b/lphybeast/src/main/java/lphybeast/tobeast/generators/CalibratedYuleToBeast.java index 6b0b6c5..532f768 100644 --- a/lphybeast/src/main/java/lphybeast/tobeast/generators/CalibratedYuleToBeast.java +++ b/lphybeast/src/main/java/lphybeast/tobeast/generators/CalibratedYuleToBeast.java @@ -37,13 +37,14 @@ public CalibratedYuleModel generatorToBEAST(CalibratedYule generator, BEASTInter calibratedYuleModel.setInputValue("birthRate", context.getAsRealParameter(generator.getBirthRate())); - Value cladeMCRAAge = generator.getCladeMRCAAge(); + Value cladeMRCAAge = generator.getCladeMRCAAge(); Value cladeTaxa = generator.getCladeTaxa(); - // unwrapping first element from array + // unwrapping first element from array, only for parameter generated from distributions. + // cause error if constant number pass in // TODO handle multiple calibrations - BasicFunction tmp = (BasicFunction) cladeMCRAAge.getInputs().get(0); + BasicFunction tmp = (BasicFunction) cladeMRCAAge.getInputs().get(0); // cladeAgeValue Value cladeAgeValue = tmp.getParams().get("0");