Learn R Programming

phylosim (version 3.0.5)

getDist.ContinuousInsertor: Get the length sampling expression

Description

Get the length sampling expression.

The length sampling expression can be any valid R expression returning a numeric vector of length one. The value returned by the expression will be rounded.

Usage

# S3 method for ContinuousInsertor
getDist(this, ...)

Arguments

this

A ContinuousInsertor object.

...

Not used.

Value

An R expression object.

See Also

For more information see ContinuousInsertor.

Examples

Run this code
# NOT RUN {
	# create object
	o<-ContinuousInsertor(rate=1)
	# set/get length sampling expression
	setDist(o, expression(rnorm(1,mean=3, sd=2)))
	getDist(o)
	# set/get length sampling expression via virtual field
	o$dist<-expression(rnorm(1,mean=6,sd=3))
	o$dist
	# set maxLength
	o$maxLength<-10
	# propose a length
	proposeLength(o)
 
# }

Run the code above in your browser using DataLab