# Product of two probabilities distributions

**URL:** <https://discourse.pymc.io/t/product-of-two-probabilities-distributions/1993>\
**Category:** Questions\
**Created:** [September 28, 2018, 2:52pm UTC](https://discourse.pymc.io/t/product-of-two-probabilities-distributions/1993 "2018-09-28T14:52:37Z")\
**Posts on this page:** 1\
**Showing post:** 8

<div class="post-metadata">

**Author:** ![Marion2025](https://avatars.discourse-cdn.com/v4/letter/m/dc4da7/32.png) [@Marion2025](https://discourse.pymc.io/u/Marion2025)\
**Post date:** [October 2, 2018, 3:40am UTC](https://discourse.pymc.io/t/product-of-two-probabilities-distributions/1993/8 "2018-10-02T03:40:35Z")

</div>

You might be able to just write a custom distribution. These two posts might be helpful.

> <https://stats.stackexchange.com/questions/248201/sum-of-product-of-bernoulli-and-normal-random-variables>

> <https://math.stackexchange.com/questions/1064541/the-product-of-a-normal-and-rademacher-variables-independent-from-each-other>

There also seems to be a similar post on this where a custom distribution and potential were used

> [@Likelihood given by product of two distributions?](https://discourse.pymc.io/t/likelihood-given-by-product-of-two-distributions/1614):
>
> I currently have a simple model: model = pm.Model() with model: # Priors for unknown model parameters hyper\_mu = pm.Normal('hyper\_mu', mu=0, sd=10) hyper\_sd = pm.Gamma('hyper\_sd', alpha=0.01, beta=0.001) c = pm.Normal('c', mu=hyper\_mu, sd=hyper\_sd, shape=(4, 4)) # Expected probabilities (4 x 4) p = sigmoid(c) # Likelihood (sampling distribution) of observations. data, N\_data = (4 x 4) pm.Binomial('L', n=N\_data, p=p, observed=data\_successes) Where I want to obtain 4x4 param…

---

_[View the full topic](https://discourse.pymc.io/t/product-of-two-probabilities-distributions/1993)._
