Learn R Programming

phylosim (version 3.0.5)

insertSequence.Sequence: Insert a Sequence object into another Sequence object after a specified position

Description

Insert a Sequence object into another Sequence object after a specified position.

Usage

# S3 method for Sequence
insertSequence(this, insert, position, process=NA, paranoid=FALSE, ...)

Arguments

this

The target Sequence object.

insert

The Sequence object to be inserted.

position

The position after the Sequence object will be inserted.

process

The Process object performing the insertion (optional).

paranoid

If TRUE, then the consistency of teh target objects is checked more rigurously after insertion.

...

Not used.

Value

The Sequence object (invisible).

See Also

For more information see Sequence.

Examples

Run this code
# NOT RUN {
	# create some sequence objects.
	target<-NucleotideSequence(string="AAAAAAAAAAA")
	insert<-NucleotideSequence(string="GGGGGGGGGGG")
	# insert after position 5
	insertSequence(target,insert,5)
	# print the target sequence
	target
 
# }

Run the code above in your browser using DataLab