use of dr.evomodel.operators.RateSampleOperator in project beast-mcmc by beast-dev.
the class RateSampleOperatorParser method parseXMLObject.
public Object parseXMLObject(XMLObject xo) throws XMLParseException {
final double weight = xo.getDoubleAttribute(MCMCOperator.WEIGHT);
final boolean sampleAll = xo.getBooleanAttribute(SAMPLE_ALL);
TreeModel treeModel = (TreeModel) xo.getChild(TreeModel.class);
RateEvolutionLikelihood rateEvolution = (RateEvolutionLikelihood) xo.getChild(RateEvolutionLikelihood.class);
RateSampleOperator operator = new RateSampleOperator(treeModel, sampleAll, rateEvolution);
operator.setWeight(weight);
return operator;
}
Aggregations