Learn R Programming

FossilSim (version 2.4.1)

fossils.to.paleotree.record: Transforms a fossils dataframe and either taxonomy or tree into a fossilRecordSimulation object from package paleotree.

Description

Transforms a fossils dataframe and either taxonomy or tree into a fossilRecordSimulation object from package paleotree.

Usage

fossils.to.paleotree.record(fossils, tree = NULL, taxonomy = NULL)

Value

The converted paleotree record

Arguments

fossils

fossils object

tree

phylo object containing the tree. If provided and taxonomy = NULL, all speciation is assumed symmetric

taxonomy

taxonomy object. If both tree and taxonomy are provided, only taxonomy will be used.

See Also

taxonomy, fossils, paleotree.record.to.fossils

Examples

Run this code
# simulate tree
t = ape::rtree(6)
# simulate fossils using taxonomy
s = sim.taxonomy(t, 0.5, 1, 0.5)
f = sim.fossils.poisson(2, taxonomy = s)
# transform format
record = fossils.to.paleotree.record(f, taxonomy = s)

Run the code above in your browser using DataLab