Rev Language Reference


mvTreeScale - Scaling Move for Time Tree Node Ages

Scales the ages of all internal nodes in a `TimeTree` by the same factor while leaving the topology unchanged.

Usage

mvTreeScale(TimeTree tree, RealPos rootAge, RealPos delta, Bool tune, RealPos weight, Probability tuneTarget)

Arguments

tree : TimeTree (<stochastic> pass by reference)
The tree on which this move operates.
rootAge : RealPos (<stochastic> pass by reference)
The root age variable.
Default : NULL
delta : RealPos (pass by value)
The scaling factor (strength) of the proposal.
Default : 1
tune : Bool (pass by value)
Should we tune the scaling factor during burnin?
Default : TRUE
weight : RealPos (pass by value)
The weight determines the relative frequency with which this move will be attempted. For details, see the description of the 'moveschedule' parameter on the documentation page for 'mcmc()'.
Default : 1
tuneTarget : Probability (pass by value)
The acceptance probability targeted by auto-tuning.
Default : 0.44

Details

The `mvTreeScale` move scales the ages of all internal nodes (including the root) by a random factor of exp(delta * (u - 0.5)), where delta is a tuning parameter and u is a random draw from the uniform distribution on [0, 1].

Example

taxa <- v(taxon("A"), taxon("B"), taxon("C"), taxon("D"), taxon("E"), taxon("F"))
height ~ dnUniform(0, 10)
moves = VectorMoves()

# Simulate a simple TimeTree
tree ~ dnBDP(lambda=1.0, mu=0.2, rootAge=height, taxa=taxa)

# Assign it a mvTreeScale move
moves.append( mvTreeScale(tree=tree, rootAge=height, delta=1, tune=TRUE, weight=5) )

See Also