Skip to content

Commit

Permalink
use getAsRealParameter #133
Browse files Browse the repository at this point in the history
  • Loading branch information
walterxie committed Feb 20, 2024
1 parent 60383fa commit feb6a62
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import beast.base.core.BEASTInterface;
import beast.base.evolution.speciation.YuleModel;
import beast.base.inference.parameter.RealParameter;
import lphy.base.evolution.birthdeath.Yule;
import lphybeast.BEASTContext;
import lphybeast.GeneratorToBEAST;
Expand All @@ -13,7 +14,8 @@ public YuleModel generatorToBEAST(Yule generator, BEASTInterface value, BEASTCon
YuleModel yuleModel = new YuleModel();

yuleModel.setInputValue("tree", value);
yuleModel.setInputValue("birthDiffRate", context.getBEASTObject(generator.getBirthRate()));
RealParameter b = context.getAsRealParameter(generator.getBirthRate());
yuleModel.setInputValue("birthDiffRate", b);
yuleModel.initAndValidate();

return yuleModel;
Expand Down

0 comments on commit feb6a62

Please sign in to comment.