ape (version 2.2-3)

NPRS.criterion: Objective Function Employed in Nonparametric Rate Smoothing

Description

NPRS.criterion computes the objective function to be minimized in the NPRS (nonparametric rate smoothing) algorithm described in Sanderson (1997).

Usage

NPRS.criterion(phy, chrono, expo = 2, minEdgeLength = 1e-06)

Arguments

Value

NPRS.criterion returns the value of the objective function given a phylogram and a chronogram.

Details

Please refer to Sanderson (1997) for mathematical details. Note that is is not computationally efficient to optimize the branch lengths in a chronogram by using NPRS.criterion - please use chronogram instead.

References

Sanderson, M. J. (1997) A nonparametric approach to estimating divergence times in the absence of rate constancy. Molecular Biology and Evolution, 14, 1218--1231.

See Also

ratogram, chronogram

Examples

Run this code
# get tree
data("landplants.newick") # example tree in NH format
tree.landplants <- read.tree(text = landplants.newick)

# plot tree
tree.landplants
plot(tree.landplants, label.offset = 0.001)

# estimate chronogram
chrono.plants <- chronogram(tree.landplants)

# plot
plot(chrono.plants, label.offset = 0.001)

# value of NPRS function for our estimated chronogram
NPRS.criterion(tree.landplants, chrono.plants)

Run the code above in your browser using DataCamp Workspace