weibull_adstock#
- pymc_marketing.mmm.transformers.weibull_adstock(x, lam=1, k=1, l_max=12, axis=0, type=WeibullType.PDF)[source]#
Weibull Adstocking Transformation.
This transformation is similar to geometric adstock transformation but has more degrees of freedom, adding more flexibility.
(
Source code
,png
,hires.png
,pdf
)- Parameters:
x (tensor) – Input tensor.
lam (float, by default 1.) – Scale parameter of the Weibull distribution. Must be positive.
k (float, by default 1.) – Shape parameter of the Weibull distribution. Must be positive.
l_max (int, by default 12) – Maximum duration of carryover effect.
type (WeibullType or str, by default WeibullType.PDF) – Type of Weibull adstock transformation to be applied (PDF or CDF).
- Returns:
Transformed tensor based on Weibull adstock transformation.
- Return type:
tensor