pgamma(15, shape = 30, rate = 2)[1] 0.524283
1 - ppois(29, lambda = 30) [1] 0.524283
F15 <- pgamma(15, shape = 30, rate = 2)
F10 <- pgamma(10, shape = 30, rate = 2)
(F15 - F10) / (1 - F10)[1] 0.5136722
pchisq(12, df = 8) - pchisq(4, df = 8)[1] 0.7059196
pgamma(12, shape = 4, rate = 1/2) - pgamma(4, shape = 4, rate = 1/2)[1] 0.7059196