$X,Y,Z$ are random variables. How to construct an example when $X$ and $Z$ are correlated, $Y$ and $Z$ are correlated, but $X$ and $Y$ are independent?
2 Answers
$\begingroup$
$\endgroup$
5
Intuitive example: $Z = X + Y$, where $X$ and $Y$ are any two independent random variables with finite nonzero variance.
-
4$\begingroup$ Or for that matter $Z=\max\{X,Y\}$. $\endgroup$Greg Martin– Greg Martin2020-11-30 07:49:26 +00:00Commented Nov 30, 2020 at 7:49
-
3$\begingroup$ @GregMartin That is not guaranteed to work unless the supports of $X$ and $Y$ overlap $\endgroup$Henry– Henry2020-11-30 10:08:09 +00:00Commented Nov 30, 2020 at 10:08
-
$\begingroup$ @henry Nice point. But you don't even need them to overlap. Just that there exist values in $X$ which are smaller than some values in $Y$ and vice versa. E.g. discontinuous piece wise functions with no overlap can work. $\endgroup$Dale C– Dale C2020-11-30 11:32:57 +00:00Commented Nov 30, 2020 at 11:32
-
$\begingroup$ @DaleC - When I said "overlap" I meant that the minimum of each was less than the maximum of the other. $\endgroup$Henry– Henry2020-11-30 11:45:02 +00:00Commented Nov 30, 2020 at 11:45
-
4$\begingroup$ A narrative example: two small kids from a soccer team trying to sneak into a movie by one sitting on the shoulders of the other and wearing a trench coat. Z is the height of the "man"; X and Y are the heights of the kids $\endgroup$Dancrumb– Dancrumb2020-11-30 23:40:43 +00:00Commented Nov 30, 2020 at 23:40
$\begingroup$
$\endgroup$
Roll two dice.
X is the number on the first die, Z is the sum of the two dice, Y is the number on the second die
X and Z are correlated, Y and Z are correlated, but X and Y are completely independent.
(This is a concrete instance of the answer given by fblundun, but I came up with it before seeing their answer.)