Skip to content


class Sampler < Object

Abstract sampler.

The Sampler class hierarchy is as follows:

Member Variables

Name Description
nsamples:Integer Number of samples to draw.
verbose:Boolean Enable verbose reporting on the terminal?

Member Functions

Name Description
setArchetype Set the archetype.

Member Fibers

Name Description
sample Sample the model.

Member Function Details


function setArchetype(m:Model)

Set the archetype. This is an instance of the model of interest with zero or more random variates already assigned in order to condition on those assigned values. It represents the target distribution of the inference problem. The sampler will check whether the archetype is of an appropriate type, and may produce an error if this is not the case.

Member Fiber Details


fiber sample() -> (Model, Real)

Sample the model.

Yield: weighted samples.