Skip to contents

This is the abstract base class for sampling objects like Sampler1D, SamplerHierarchical or SamplerJointIndep.

Public fields

param_set

(ParamSet)
Domain / support of the distribution we want to sample from.

Methods


Method new()

Creates a new instance of this R6 class.

Note that this object is typically constructed via derived classes, e.g., Sampler1D.

Usage

Sampler$new(param_set)

Arguments

param_set

(ParamSet)
The ParamSet to associated with this Sampler.


Method sample()

Sample n values from the distribution.

Usage

Sampler$sample(n)

Arguments

n

(integer(1)).

Returns

Design.


Method format()

Helper for print outputs.

Usage

Sampler$format(...)

Arguments

...

(ignored).


Method print()

Printer.

Usage

Sampler$print(...)

Arguments

...

(ignored).


Method clone()

The objects of this class are cloneable with this method.

Usage

Sampler$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.