getParameterAtSites.Sequence: Get the values of a site-process specific paramater for a...

Description Usage Arguments Value Author(s) See Also Examples

Description

Get the values of a site-process specific paramater for a process and a collection of Site objects aggregated by a Sequence object.

Usage

1
2
## S3 method for class 'Sequence'
getParameterAtSites(this, process, id, index, ...)

Arguments

this

A Sequence object.

process

A valid Process object.

id

The identifier of the site-process specific parameter.

index

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

...

Not used.

Value

A list of site specific paramters. A site specific paramter is a list storing the id, the name, the value and the type of the parameter.

Author(s)

Botond Sipos, Gregory Jordan

See Also

Site Process For more information see Sequence.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
	# create a sequence, attach a process
	p<-K80()
	s<-Sequence(length=6,alphabets=list(NucleotideAlphabet()),processes=list(list(p)))
	# set a new pattern of rate multipliers in the
   # range 1:3, the default value is 1.0 by the way
	setParameterAtSites(s,p,"rate.multiplier",c(2,3),1:3)
	# get rate multipliers
	getParameterAtSites(s,p,"rate.multiplier")
	# set a new value for the whole sequence
	setParameterAtSites(s,p,"rate.multiplier",0.5)
	# get rate multipliers
	getParameterAtSites(s,p,"rate.multiplier")
 

phylosim documentation built on Nov. 22, 2019, 1:07 a.m.