Search in sources :

Example 1 with FunkyPriorMixerOperator

use of dr.evomodel.operators.FunkyPriorMixerOperator in project beast-mcmc by beast-dev.

the class FunkyPriorMixerOperatorParser method parseXMLObject.

public Object parseXMLObject(XMLObject xo) throws XMLParseException {
    CoercionMode mode = CoercionMode.parseMode(xo);
    double weight = xo.getDoubleAttribute(MCMCOperator.WEIGHT);
    double windowSize = xo.getDoubleAttribute(WINDOW_SIZE);
    Parameter parameter = (Parameter) xo.getChild(Parameter.class);
    TreeModel treeModel = (TreeModel) xo.getChild(TreeModel.class);
    RandomWalkOperator.BoundaryCondition condition = RandomWalkOperator.BoundaryCondition.valueOf(xo.getAttribute(BOUNDARY_CONDITION, RandomWalkOperator.BoundaryCondition.reflecting.name()));
    return new FunkyPriorMixerOperator(treeModel, parameter, windowSize, condition, weight, mode);
}
Also used : RandomWalkOperator(dr.inference.operators.RandomWalkOperator) TreeModel(dr.evomodel.tree.TreeModel) Parameter(dr.inference.model.Parameter) CoercionMode(dr.inference.operators.CoercionMode) FunkyPriorMixerOperator(dr.evomodel.operators.FunkyPriorMixerOperator)

Aggregations

FunkyPriorMixerOperator (dr.evomodel.operators.FunkyPriorMixerOperator)1 TreeModel (dr.evomodel.tree.TreeModel)1 Parameter (dr.inference.model.Parameter)1 CoercionMode (dr.inference.operators.CoercionMode)1 RandomWalkOperator (dr.inference.operators.RandomWalkOperator)1