Patterns in static

Apophenia

apop_mixture_settings Struct Reference

Data Fields

apop_modelcmf
 
int * cmf_refct
 
char find_weights
 
int model_count
 
apop_model ** model_list
 
gsl_vector * next_weights
 
int * param_sizes
 
gsl_vector * weights
 

Detailed Description

For mixture distributions, typically set up using apop_model_mixture. See apop_mixture for discussion. Please consider all elements but model_list and weights as private and subject to change. See the examples for use of these elements.

Field Documentation

apop_model * apop_mixture_settings::cmf

For internal use by the draw method.

int * apop_mixture_settings::cmf_refct

For internal use, so I can garbage-collect the CMF when needed.

char apop_mixture_settings::find_weights

By default, weights are fixed. Set this b 'y' to allow apop_estimate to use an EM algorithm to find the optimal weights. See the documentation for apop_mixture for details.

apop_model ** apop_mixture_settings::model_list

A NULL-terminated list of component models.

gsl_vector * apop_mixture_settings::next_weights

For internal use.

int * apop_mixture_settings::param_sizes

The number of parameters for each model. Useful for unpacking the params.

gsl_vector * apop_mixture_settings::weights

The likelihood of a draw from each component. Default is equal likelihood for each mixture element. Or set this to a weight vector of your choosing, or set find_weights='y' and have apop_estimate find optimal weights.