Learn R Programming

phylosim (version 3.0.5)

getEvents.Site: Get the list of active event objects given the current state of the Site object

Description

Get the list of active event objects given the current state of the Site object. The list of active event object might change according to the state of the Site object.

Usage

# S3 method for Site
getEvents(this, ...)

Arguments

this

A Site object.

...

Not used.

Value

A list of event objects.

See Also

For more information see Site.

Examples

Run this code
# NOT RUN {
	# create a site object with a JC69 substitution process attached
	s<-Site(alphabet=NucleotideAlphabet(), state="A",processes=list(JC69()))
	# get the list of active event objects
	getEvents(s)
	# modify site state
	s$state<-"T"
	# get the list of active event objects via virtual field
	s$events

 
# }

Run the code above in your browser using DataLab