pymc.step_methods.CategoricalGibbsMetropolis#
- class pymc.step_methods.CategoricalGibbsMetropolis(*args, **kwargs)[source]#
A Metropolis-within-Gibbs step method optimized for categorical variables.
This step method works for Bernoulli variables as well, but it is not optimized for them, like BinaryGibbsMetropolis is. Step method supports two types of proposals: A uniform proposal and a proportional proposal, which was introduced by Liu in his 1996 technical report “Metropolized Gibbs Sampler: An Improvement”.
Methods
CategoricalGibbsMetropolis.__init__
(vars[, ...])CategoricalGibbsMetropolis.astep
(apoint, *args)Perform a single sample step in a raveled and concatenated parameter space.
CategoricalGibbsMetropolis is only suitable for Bernoulli and Categorical variables.
Perform a single step of the sampler.
Attributes
name
sampling_state
stats_dtypes
A list containing <=1 dictionary that maps stat names to dtypes.
stats_dtypes_shapes
Maps stat names to dtypes and shapes.
vars
Variables that the step method is assigned to.