aesara-devs / aemcmc

AeMCMC is a Python library that automates the construction of samplers for Aesara graphs representing statistical models.
https://aemcmc.readthedocs.io/en/latest/
MIT License
39 stars 11 forks source link

The mathematical expression of the relation in `scale_loc_transform` does not correspond to this transform #59

Closed rlouf closed 2 years ago

rlouf commented 2 years ago

The current docstring contains the following relation:

$$
\begin{equation} \frac{ X \sim \operatorname{N}\left(\mu_x, \sigma_x^2\right), \quad Y \sim \operatorname{N}\left(\mu_y, \sigma_y^2\right), \quad X + Y = Z }{ Z \sim \operatorname{N}\left(\mu_x + \mu_y, \sigma_x^2 + \sigma_y^2\right) } \end{equation} $$

when we want:

$$ \begin{equation} \frac{ Y \sim \operatorname{P}(0, 1), \quad X = \mu + \sigma\,Y }{ X \sim \operatorname{P}\left(\mu, \sigma\right) } \end{equation} $$

brandonwillard commented 2 years ago

Does $\operatorname{P}$ represent an arbitrary location-scale-parameterized measure? That would need an explanation in the docstring.