reject_missing_coords#

pymc_marketing.mmm.optimization_variables.reject_missing_coords(da, coords, *, label)[source]#

Refuse an input that does not cover every coordinate the model has.

Parameters:
  • da (DataArray | Dataset) – User-supplied input carrying some or all of the model’s dims.

  • coords (Mapping[str, list]) – The model’s coordinates for those dims.

  • label (str) – Name of the input, used in the error message.

Raises:

ValueError – If the input lacks coordinates the model has, on a dim it carries.