Bayesian lognormal model: how to correctly back-transform the estimates?

I have a Bayesian model of the form:

\begin{align} y & \sim logNormal(\mu, \sigma)\\ \mu_n & = \alpha + \beta_0 c_n + \beta_1 d_n + \beta_2 c_n d_n \end{align} Where:

• $$y$$ is a variable measured in ms
• $$c$$ is a sum-contrast coded variable equal to 1 or -1.
• $$d$$ is a scaled and centered continuous variable

This omits assumed prior distributions, and slope and intercept adjustments, I believe they are not important with respect to the main point. Since the likelihood is logNormal the results are on the log scale.

I want to back-transform the estimates from the model and compute the effect sizes of different variables. I think I know how to do this for $$c$$:

$$\mu|_{c=1} - \mu|_{c=-1} = \exp (\alpha + \beta_0 + \beta_1 d_n + \beta_2 d_n ) - \exp (\alpha - \beta_0 + \beta_1 d_n - \beta_2 d_n )$$

For interaction this is slightly more complicated. Let the interaction effect be: $$IE = \frac{\partial \mu}{\partial d}|_{c = 1} - \frac{\partial \mu}{\partial d}|_{c = -1}$$. I remove the log by exponentiation and then I take the derivative which results in:

$$\frac{\partial \mu}{\partial d} = \exp (\alpha + \beta_0 c_n + \beta_1 d_n + \beta_2 c_n d_n ) (\beta_1 + \beta_2 c_n)$$

So the interaction effect is the difference of these two terms:

\begin{align} \frac{\partial \mu}{\partial d}|_{c = 1} = & \exp (\alpha + \beta_0 + \beta_1 d_n + \beta_2 d_n ) (\beta_1 + \beta_2) \\ \frac{\partial \mu}{\partial d}|_{c = -1} = & \exp (\alpha - \beta_0 + \beta_1 d_n - \beta_2 d_n ) (\beta_1 - \beta_2) \\ \end{align}

My questions are:

1. Are the derivations for the interaction effect and the effect of $$c$$ correct? If yes, this means that these effects are functions of $$d$$, but fitting the model returns the effects (on the log scale) as constants. Where does this difference come from?
2. How do I derive and interpret the effect for $$d$$? Ie. what are the meaningful points at which to evaluate the function $$\mu$$? Or maybe is there a better way of doing this?
• Small nitpick on notation. Shouldn't it be (for example) $\partial \mu / \partial d$ instead of $\partial y / \partial d$? $y$ is a random variable, so it does not immediately make sense to take its derivative. Similarly, should $y |_{c=1}$ instead be $\mu |_{c = 1}$? Mar 10, 2021 at 18:52
• @stats_model Yes, I think you're right. Thanks, I'll correct it.
– jjj
Mar 10, 2021 at 21:21

The effect size of a log-normal model has not a univoque value on the same scale of y, because of the log-relation between $$\mu$$ and the position of the log-normal distribution (its median, its mean). When changing a covariate, the model predictions move linearly with the covariate on the log scale, not on the original scale, so on the log scale there is a constant effect size, while on the original scale there is not, it varies.
• Thanks for answering this is helpful. One question/remark though: is this correct to call the likelihood here a "link function"? I thought the link would be eg. $f$ if the model was specified like $f(\mu) = \ldots$. Even more in the brms package it's explicitly stated that the link for lognormal is "identity".
• likelihood and link functions are not the same thing, link functions really apply only to GLMs, and this is not a GLM, but I used the term hoping it would make things clearer. You are also right about the fact that $\mu$ here is equal to the linear predictor, not a transformation (so we may say link function is identity). What I intended is that the position of the predictive distribution (its median, its expected value) vary with the exponential of the linear predictor. Mar 16, 2021 at 16:18