pymc.model.core.Model.register_rv#

Model.register_rv(rv_var, name, *, observed=None, total_size=None, dims=None, default_transform=UNSET, transform=UNSET, initval=None)[source]#

Register an (un)observed random variable with the model.

Parameters:
rv_varTensorVariable
namestr

Intended name for the model variable.

observedarray_like, optional

Data values for observed variables.

total_sizescalar

upscales logp of variable with coef = total_size/var.shape[0]

dimstuple

Dimension names for the variable.

default_transform

A default transform for the random variable in log-likelihood space.

transform

Additional transform which may be applied after default transform.

initval

The initial value of the random variable.

Returns:
TensorVariable