8
$\begingroup$

I'm new to statistics and I'm struggling to solve a question from an assignment. I have a probability density function and I need to calculate its median

Here is the function:

$$f(x) = 2xe^{-x^2}, x>= 0$$

The answer is $\sqrt{\log 2}$.

Can someone help? I'm trying to learn

$\endgroup$
3
  • 1
    $\begingroup$ $f$ obviously is not a PDF, because it takes on negative values when $x$ is negative. It is probably intended that $f(x)=0$ when $x\le 0$, but--especially for solving problems that involve computing with PDFs--it is crucial that you specify this explicitly. $\endgroup$
    – whuber
    Mar 20, 2016 at 23:22
  • $\begingroup$ What is the definition of median? Start from there. $\endgroup$ Mar 20, 2016 at 23:22
  • $\begingroup$ You're right whuber, I re-read my assignment and edited the question. $f(x)$ is 0 when x < 0 $\endgroup$
    – Rods2292
    Mar 20, 2016 at 23:26

1 Answer 1

26
$\begingroup$

A median by definition is a real number $m$ that satisfies $$P(X\leq m)=\frac{1}{2}.$$ So in your case, we have $$\int_0^m2xe^{-x^2}\,dx=\frac{1}{2}.$$ How do you solve for $m$ then? Hint: integration by substitution.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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