Take the 2-minute tour ×
Cross Validated is a question and answer site for people interested in statistics, machine learning, data analysis, data mining, and data visualization. It's 100% free, no registration required.

I have two functions $f_x$ = $\frac{1}{2}\delta(x-5) + 1/4$ where the 1/4 corresponds to a uniform distribution from 5 to 7. I also have $f_{y|x}$ = $\frac {1}{2}\delta(y-x-4) + 1/4$ which is 1/4 in the range of x+4 to x+6. I am trying to find $f_y$ using the equation: $$ f_y = \int f_x f_{y|x} \,\mathrm dx \>. $$ My question is: How do I find the limits of this integration? I had thought something like integrating from $y-4$ to $y-6$ but that doesn't really seem correct.

share|improve this question
Deficiencies in your notation may be causing some confusion. Presumably "$\delta$" represents the point measure at zero. Don't, however, conflate constants with uniform distributions! For instance, your first "$1/4$" could more explicitly be written as $1/4 I_{[5,7]}(x)$ where $I_A$ is the indicator function for a set $A$. (This is a guess: I presume you intend $f_x dx$ to be a probability measure.) When you do this, the limits of integration do not matter: all integrals can be viewed as being over the entire Real line. –  whuber Jan 14 '13 at 15:24
Right, sorry I'm bad about leaving out specifics sometimes. I understand that ${\bf f_x}$ is only valid between 5 and 7 and that my ${\bf f_{y|x}}$ is valid only between x+4 and x+6. I think that this would mean that my resulting answer for ${\bf f_y}$ would only be valid between 9 and 13? I'm just not totally sure how to get there. –  nomad2986 Jan 14 '13 at 17:38
I think confusion may arise in part due to your notation. When you write $f_{y|x}$, it reads as though you are thinking of $y$ and $x$ as separate random variables drawn from a joint distribution. However, your narrative suggests that you intend for $y$ to be a function of $x$. In this latter case, once $x$ is known, $y$ is known: the distribution of $y$ conditioned on $x$ is a single point, $y(x)$. Which is it? –  Arthur Small Jan 14 '13 at 19:16
So your model could be written: $x_1 \sim Unif(5,7)$, $x_2 \sim Unif(4,6)$, $y=x_1+x_2$; and your question is, What is the distribution of $y$. Is this correct? –  Arthur Small Jan 14 '13 at 20:12
If so, and if $x_2$ does not depend on $x_1$ in any way, then the answer's pretty obvious: $y \sim Unif(9,13)$. –  Arthur Small Jan 14 '13 at 20:15
show 2 more comments

1 Answer

up vote 2 down vote accepted

@whuber is correct on both counts (and should be given credit for an accepted answer, imho).

In general, to derive a marginal distribution, you integrate the joint distribution over the entire support of the variable you are integrating out. In this case, integrating wrt $x$ over the entire real line gives the correct answer.

Working from first principles: recall how a conditional distribution is defined in terms of a joint distribution:

$f(x,y) = f(y \mid x) f(x)$

The marginal distribution of $y$ is given by integrating out $x$ over its entire support (the closure of the set on which $x \ne 0$). You get the same answer if you integrate over the entire real line:

$f(y) = \int_\mathbb{R} f(x,y) dx = \int_\mathbb{R} f(y \mid x) f(x) dx$.

share|improve this answer
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.