I would appreciate if anyone could help me understand the difference between marginal effects and effect modification in `brms`

's `marginal_effects.brmsfit`

and in emmeans estimation based on a `brms`

model.

The `marginal effects`

are defined as “instantaneous rates of change: for a dichotomous explanatory variable, a marginal effect shows how predicted probabilities change when the variable changes from 0 to 1” here are elsewhere.

On the other hand, `effect modification`

here and elsewhere is defined as “when the magnitude of the effect of the primary exposure on an outcome (i.e., the association) differs depending on the level of a third variable”.

Furthermore, the `brms`

documentation says “Since we condition on rather than actually marginalizing variables, the name marginal_effects is possibly not ideally chosen in retrospect.”

And the documentation of `emmeans`

states that " … EMMs are based on a *model* . Neither of these plots is an interaction plot of the *data* ; they are interaction plots of model predictions; and since both models do not include an interaction, no interaction at all is evident in the plots."

I fail to see where the overlap between these two measures ends. Specifically, what is the difference between `marginal effects without interaction`

and `marginal effects with interaction`

in `brms`

in terms of their meaning?