CLVModel#

class pymc_marketing.clv.models.basic.CLVModel(data, *, model_config=None, sampler_config=None, non_distributions=None)[source]#

CLV Model base class.

Methods

CLVModel.__init__(data, *[, model_config, ...])

Initialize model configuration and sampler configuration for the model.

CLVModel.attrs_to_init_kwargs(attrs)

Convert the model configuration and sampler configuration from the attributes to keyword arguments.

CLVModel.build_from_idata(idata)

Build the model from the InferenceData object.

CLVModel.build_model(**kwargs)

Create an instance of pm.Model based on provided data and model_config.

CLVModel.create_idata_attrs()

Create attributes for the inference data.

CLVModel.fit([method, fit_method])

Infer model posterior.

CLVModel.fit_summary(**kwargs)

Compute the summary of the fit result.

CLVModel.graphviz(**kwargs)

Get the graphviz representation of the model.

CLVModel.idata_to_init_kwargs(idata)

Create the initialization kwargs from an InferenceData object.

CLVModel.load(fname[, check])

Create a ModelBuilder instance from a file.

CLVModel.load_from_idata(idata[, check])

Create a ModelBuilder instance from an InferenceData object.

CLVModel.save(fname, **kwargs)

Save the model's inference data to a file.

CLVModel.set_idata_attrs([idata])

Set attributes on an InferenceData object.

CLVModel.table(**model_table_kwargs)

Get the summary table of the model.

CLVModel.thin_fit_result(keep_every)

Return a copy of the model with a thinned fit result.

Attributes

default_model_config

Return a class default configuration dictionary.

default_sampler_config

Default sampler configuration.

fit_result

Get the posterior fit_result.

id

Generate a unique hash value for the model.

posterior

posterior_predictive

predictions

prior

prior_predictive

version

idata

sampler_config

model_config