# Create simple four-taxon tree with edge lengths all
# set to 1 Ma:
time_tree <- ape::read.tree(text = "(A:1,(B:1,(C:1,D:1):1):1);")
# Set root.time as 10 Ma:
time_tree$root.time <- 10
# Get node ages:
date_nodes(time_tree = time_tree)
Run the code above in your browser using DataLab