Methods to extract coefficients from various cross-price demand model objects.
# S3 method for cp_model_nls
coef(object, ...)# S3 method for cp_model_lm
coef(object, ...)
# S3 method for cp_model_lmer
coef(object, fixed_only = FALSE, combine = TRUE, ...)
Named vector of coefficients
A named numeric vector of model coefficients.
A cp_model_lm object
Additional arguments (not used).
Logical; if TRUE, returns only fixed effects. Default is FALSE.
Logical; if TRUE and fixed_only=FALSE, returns fixed + random effects combined. Default is TRUE.
coef(cp_model_nls): Extract coefficients from a nonlinear cross-price model
coef(cp_model_lm): Extract coefficients from a linear cross-price model
coef(cp_model_lmer): Extract coefficients from a mixed-effects cross-price model