Learn R Programming

phylosim (version 3.0.5)

attachProcess.Sequence: Attach a Process object to a set of Site objects aggregated by a Sequence object

Description

Attach a Process object to a set of Site objects aggregated by a Sequence object.

Usage

# S3 method for Sequence
attachProcess(this, process, index, ...)

Arguments

this

A Sequence object.

process

A Process object.

index

An integer vector specifying a set of positions. It is set to 1:seq$length if omitted.

...

Not used.

Value

The Sequence object (invisible).

See Also

For more information see Sequence.

Examples

Run this code
# NOT RUN {
	# create a Sequence object of length 6
	s<-Sequence(length=10,alphabets=list(NucleotideAlphabet()))
	# attach a JC69 substitution process
	attachProcess(s,JC69())
	# get the list of attached processes
	s$processes
	# attach the GTR substitution process to range 3:6
	attachProcess(s,GTR(),3:6)
	# get the list of attached processes
	s$processes
 
# }

Run the code above in your browser using DataLab