1
$\begingroup$

so I understand how to calculate the 0.5 quantile of the given question. I calculate the CDF of x and then I multiply it to 0.5 But what if there's more than one function for multiple intervals? How can I calculate the 0.5 quantile of that? The blue is what I am trying to find the 0.5 quantile of. It's the CDF I found from the PDF.

enter image description here

enter image description here enter image description here

$\endgroup$
  • $\begingroup$ You integrate up to the point of interest, piecewise if necessary. In other words, you "break up" the integral piecewise. $\endgroup$ – Em. Jun 5 '16 at 23:24
1
$\begingroup$

The calculated cdf is not quite right. We have $F(x)$ for $x\le 0$, and $F(x)=\frac{x}{12}$ for $0\lt x\lt 2$. We also have $F(x)=\frac{1}{6}$ between $2$ and $5$. So far fine.

Between $x=5$ and $x=10$, we have $$F(x)=\Pr(X\le x)=\frac{1}{6}+2\cdot\frac{x-5}{12},$$ which is $\frac{x-4}{6}$. More generally, we can write for $x$ in this interval $$F(x)=F(5)+\int_5^x f(t)\,dt.$$

And finally $F(x)=0$ for $x\ge 10$.

The median ($0.5$ quantile) is located in the interval from $5$ to $10$. To find it, we solve $\frac{x-4}{6}=0.5$.

$\endgroup$
  • $\begingroup$ Oh! Woah that's odd. My teacher's solution to the question matches up to mine, I'm assuming he's wrong then right? (gyazo.com/2de75b3859c8dcadd83412c0d771b660) Also I'm a bit confused as to how the 0.5 quantile is located in the interval from 5 to 10. Shouldn't it be from 0 to 2? I might be thinking of it too literally in terms of the number $\endgroup$ – NookLines Jun 5 '16 at 23:41
  • 1
    $\begingroup$ You can check that $\frac{x-5}{10}$ between $5$ and $10$ is wrong in several ways. For example at a tiny bit past $5$, it gives probability near $0$, while of course we know there is a fair bit of weight (probability) in the interval up to $5$, namely $1/6$. Also $\frac{x-5}{6}$ gives the wrong answer at $x=10$. We have $1/6$ of the weight before $5$, and the bulk of the weight, $5/6$ of it, between $5$ and $10$. So the median will be between $5$ and $10$, roughly halfway but not quite because of the weight between $0$ and $5$. Solving, we get median $7$. $\endgroup$ – André Nicolas Jun 5 '16 at 23:48
  • 1
    $\begingroup$ The language of quantiles is not quite uniform. One can use probabilities $0.25$, $0.5$, $0.9$, or percentages. Of course if we read $0.5$ as meaning $0.5\%$, then this quantile is not much greater than $0$. I interpreted $0.5$ as meaning $50\%$. $\endgroup$ – André Nicolas Jun 5 '16 at 23:51
  • 1
    $\begingroup$ As to your teacher's solution that you linked to in a comment, it correctly said it was the area of the first rectangle plus the area of the part of the second rectangle between $5$ and $x$. (S)he calculated that area, but then forgot to do the plus. $\endgroup$ – André Nicolas Jun 5 '16 at 23:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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