Expected value of a joint bound distribution?

21 views
Skip to first unread message

Ziv Lieberman

unread,
Dec 18, 2025, 10:26:22 PM12/18/25
to PAML discussion group
Hello all,
I'm interested in employing joint bound distributions for node priors, using unequal tail probabilities. (The motivation is that I have single fossil occurrences for taxa, so I would like to specify equal prior probability between the minimum and maximum stratum age, with a very small probability of violating the minimum, and a much larger probability of violating the maximum).
Is there a way to calculate an expected value for the joint bounds distribution, as calculated in the mcmc3r package with dB?
Thank you!
-Ziv

Sandra AC

unread,
Dec 19, 2025, 10:57:30 AM12/19/25
to PAML discussion group
Dear Ziv,

Thanks for your message! I apologise in advance if I have misunderstood your question but, are you referring to the tail probabilities of the uniform densities that you must specify if you do not want to use soft bounds (i.e., default setting to pL = pU = 0.025)? If that is the case, you may modify the tail percentages of "pL" and "pU" until you achieve the shape of the distribution that best represents your interpretation of the fossil occurrences you are incorporating in the analyses. E.g.: you can use the R function "mcmc3r::dB" to visualise whether such distributions and check whether you want to set a larger/smaller probability of being further/closer to the specified bound. If you want to set a hard bound, you will need to use "1e-300" -- this is the smallest value that will not cause numerical issues. If you want to learn more about this type of calibration density (and others) implemented in MCMCtree, you may be keen on checking the PAML Wiki for MCMCtree, specially the section "Calibrations: how to set up node age constraints?".

I hope this is somewhat helpful but, if you have further questions or something is still unclear, please do not hesitate to get back!

All the best,
Sandy

Ziv Lieberman

unread,
Dec 19, 2025, 8:42:20 PM12/19/25
to PAML discussion group
Hi Sandy,
Thank you! I actually understand the parameters, but I am wondering if there is a way to calculate a mean or other moment for a distribution with unequal soft tails. By analogy, a strict uniform distribution would have the expected value (min + max)/2. It also seems that for the truncated Cauchy, one can find the mode using tL(1+p) (Inoue et al. 2010). Is there a similar formula that would apply to a distribution specified as, e.g., B(0.57, 0.48, 0.005, 0.3)'?
Thanks!
-Ziv

Sishuo Wang

unread,
Dec 19, 2025, 11:38:40 PM12/19/25
to PAML discussion group
Hi Ziv,

I guess an answer to your q could be found from Eq. 17 from https://academic.oup.com/mbe/article/23/1/212/1193630

In your case, i assume th following calibration (note that i change 0.005 to 0.2 for simplicity in calculation)
'B(0.57, 0.48, 0.2, 0.3)'

First, you can fix \theta_1 and \theta_2 to the values that make the pdf continuous at the t_L and t_U respectively.

That said, we find out \theta_1 that satisfy 0.2 * \theta_1/0.58 = 0.5/(0.57-0.48) and \theta_2 that satisfy 0.3*\theta_2 = 0.5/(0.57-0.48)

After figuring out the values of \theta_1 and \theta_2, we can calculate the mean by simply sampling the 3 distributions with a probability of 0.2, 0.5, 0.3 and calculating the mean. Certainly this can also be calculated analytically, which is also easy enough. But i think the most important part is to find out the values of \theta_1 and \theta_2 and after this evetything becomes easy to understand. Thanks!

best,
sishuo

Ziv Lieberman

unread,
Dec 20, 2025, 12:59:15 AM12/20/25
to PAML discussion group
Hi Sishuo,
Amazing, thank  you for pointing me to the equation! Seems there's always more good stuff to find in Yang & Ranalla :)
Appreciate the help!
-Ziv
Reply all
Reply to author
Forward
0 new messages