Sum of two random variables with different distributions
Show older comments
Hi everyone,
I have a kernel cdf for variable x1 (bandwith=0.22) and an exponential cdf for variable x2 (lambda =1/14). Is there a command in Matlab that allows me to get the cdf for a new variable that is the sum of x1 and x2 (y=x1+x2)? The range of values for x2 is [0;100] and for x1 is ]0; +∞[.
Thanks in advance!
Best,
Elizabeth
1 Comment
John D'Errico
on 11 Feb 2016
Um, I see that you state that the exponential variable is limited to [0,100]. That is simply not true. An exponential CDF has support [0,inf). Given your (unknown to me) rate parameter, it may well be true that PRACTICALLY, your exponential random variable is almost always no larger than 100.
Accepted Answer
More Answers (1)
Walter Roberson
on 10 Feb 2016
1 vote
For any two distributions, as long as they are independent, the mean of the sum of a random variable from each of the two distributions, is the same as the sum of the means of the individual distributions.
The question becomes more interesting if you are clipping based upon the sum of the two rather than clipping each individually. Your (0,infinity) for x1 appears to be not be a truncated range (unless 0 would normally be part of the range), but your [0,100] for x2 is truncated, but you do not appear to be truncating based upon the two together, so the "sum of the means" still applies.
(Out of all continuous distributions, only the Uniform distribution and the Beta distribution are finite domain; all other distributions including the exponential distribution are infinite domain, so you need to do special analysis on your x2 distribution to find its mean.)
1 Comment
Elizabeth Vieira
on 11 Feb 2016
Categories
Find more on Monte-Carlo in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!