Learn R Programming

phylosim (version 3.0.5)

omegaVarM1.CodonSequence: The M1 (neutral) model of variable omega ratios among sites

Description

The M1 (neutral) model of variable omega ratios among sites.

This method sets the omega site-process specific parameter in the specified range to values sampled from the M1 (neutral) model of variable omega ratios among sites.

Distribution of omega values:

	CATEGORY	PROBABILITY

omega_0 = 0 p0 omega_1 = 1 1-p0

Usage

# S3 method for CodonSequence
omegaVarM1(this, process, p0, index, ...)

Arguments

this

A CodonSequence object.

process

A process object inheriting from GY94.

p0

See above.

index

A vector of positions.

...

Not used.

Value

Invisible TRUE.

References

Yang, Z., Nielsen, R., Goldman, N., Pedersen Krabbe, A-M. (2000) Codon-Substitution Models for Heterogeneous Selection Pressure at Amino Acid Sites - Genetics 155:431-449 http://bit.ly/bvjucn

Goldman, N., Yang, Z. (1994) A codon-based model of nucleotide substitution for protein-coding DNA sequences - Mol Biol Evol 11(5):725-36 http://bit.ly/aSVEoa

See Also

For more information see CodonSequence.

Examples

Run this code
# NOT RUN {
	# create a GY94 object
	p<-GY94(kappa=2)
	# create a CodonSequence object, attach process p
	s<-CodonSequence(length=25, processes=list(list(p)))
	# sample states
	sampleStates(s)
	# sample omegas in range 1:20 from model M1
	omegaVarM1(s,p,p0=0.5,1:20)
	# get omega values
	getOmegas(s,p)
	# get a histogram of omega values in range 1:20
	omegaHist(s,p,breaks=50,1:20)
 
# }

Run the code above in your browser using DataLab