paleotree.record.to.fossils: Transforms a fossilRecordSimulation object from package...

Description Usage Arguments Value See Also Examples

View source: R/conversions.R

Description

The returned tree is in paleotree format, with zero-length edges leading to tips at bifurcation and anagenetic events. Fossils and taxonomy are only specified on non-zero-length edges. The label assigned to the parent of the origin or root will be zero.

Usage

1

Arguments

record

fossilRecordSimulation object.

alphanumeric

If TRUE function will return alphanumeric species labels (i.e. species labels contain the "t" prefix) (default). If FALSE function will return numeric only species labels.

Value

A list containing the converted tree, taxonomy and fossils

See Also

taxonomy, fossils, fossils.to.paleotree.record

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
if (requireNamespace("paleotree", quietly = TRUE)) {
# simulate record
record = paleotree::simFossilRecord(p=0.1, q=0.1,r=0.1, nruns=1, nTotalTaxa=c(30,40),
    nExtant=0, nSamp = c(5,25))

# transform format
l_tf = paleotree.record.to.fossils(record)
l_tf$tree
l_tf$taxonomy
l_tf$fossils
}

FossilSim documentation built on May 1, 2019, 10:52 p.m.