Learn R Programming

phylosim (version 3.0.5)

getAncestral.Sequence: Get the ancestral object of a Sequence object

Description

Get the ancestral object of a Sequence object.

Usage

# S3 method for Sequence
getAncestral(this, ...)

Arguments

this

A Sequence object.

...

Not used.

Value

A Sequence object or a Process object.

See Also

For more information see Sequence.

Examples

Run this code
# NOT RUN {
	# create a sequence object
	s<-Sequence(length=4)
	# get ancestral object
	getAncestral(s)	# newly created sequences have the "Root insertion process" as ancestral
	# clone sequence
	cs<-clone(s)
	# get ancestral object id via virtual field
	cs$ancestral$id
 
# }

Run the code above in your browser using DataLab