Find expected value using CDF - Cross Validated most recent 30 from stats.stackexchange.com 2019-11-14T09:16:03Z https://stats.stackexchange.com/feeds/question/10159 https://creativecommons.org/licenses/by-sa/4.0/rdf https://stats.stackexchange.com/q/10159 33 Find expected value using CDF styfle https://stats.stackexchange.com/users/4401 2011-04-29T22:30:31Z 2019-08-31T04:55:06Z <p>I'm going to start out by saying this is a homework problem straight out of the book. I have spent a couple hours looking up how to find expected values, and have determined I understand nothing.</p> <blockquote> <p>Let <span class="math-container">$X$</span> have the CDF <span class="math-container">$F(x) = 1 - x^{-\alpha}, x\ge1$</span>.<BR> Find <span class="math-container">$E(X)$</span> for those values of <span class="math-container">$\alpha$</span> for which <span class="math-container">$E(X)$</span> exists.</p> </blockquote> <p>I have no idea how to even start this. How can I determine which values of <span class="math-container">$\alpha$</span> exist? I also don't know what to do with the CDF (I'm assuming this means Cumulative Distribution Function). There are formulas for finding the expected value when you have a frequency function or density function. Wikipedia says the CDF of <span class="math-container">$X$</span> can be defined in terms of the probability density function <span class="math-container">$f$</span> as follows:</p> <p><span class="math-container">$F(x) = \int_{-\infty}^x f(t)\,dt$</span></p> <p>This is as far as I got. Where do I go from here?</p> <p>EDIT: I meant to put <span class="math-container">$x\ge1$</span>.</p> https://stats.stackexchange.com/questions/10159/-/10161#10161 19 Answer by Henry for Find expected value using CDF Henry https://stats.stackexchange.com/users/2958 2011-04-29T23:21:56Z 2011-04-30T09:54:18Z <p><strong>Edited for the comment from probabilityislogic</strong></p> <p>Note that $F(1)=0$ in this case so the distribution has probability $0$ of being less than $1$, so $x \ge 1$, and you will also need $\alpha &gt; 0$ for an increasing cdf. </p> <p>If you have the cdf then you want the anti-integral or derivative which with a continuous distribution like this </p> <p>$$f(x) = \frac{dF(x)}{dx}$$ </p> <p>and in reverse $F(x) = \int_{1}^x f(t)\,dt$ for $x \ge 1$.</p> <p>Then to find the expectation you need to find </p> <p>$$E[X] = \int_{1}^{\infty} x f(x)\,dx$$ </p> <p>providing that this exists. I will leave the calculus to you.</p> https://stats.stackexchange.com/questions/10159/-/10168#10168 8 Answer by probabilityislogic for Find expected value using CDF probabilityislogic https://stats.stackexchange.com/users/2392 2011-04-30T07:59:08Z 2011-04-30T13:59:33Z <p>I think you actually mean $x\geq 1$, otherwise the CDF is vacuous, as $F(1)=1-1^{-\alpha}=1-1=0$.</p> <p>What you "know" about CDFs is that they eventually approach zero as the argument $x$ decreases without bound and eventually approach one as $x \to \infty$. They are also non-decreasing, so this means $0\leq F(y)\leq F(x)\leq 1$ for all $y\leq x$.</p> <p>So if we plug in the CDF we get:</p> <p>$$0\leq 1-x^{-\alpha}\leq 1\implies 1\geq \frac{1}{x^{\alpha}}\geq 0\implies x^{\alpha}\geq 1 &gt; 0\implies x\geq 1 \&gt;.$$</p> <p>From this we conclude that the support for $x$ is $x\geq 1$. Now we also require $\lim_{x\to\infty} F(x)=1$ which implies that $\alpha&gt;0$</p> <p>To work out what values the expectation exists, we require:</p> <p>$$\newcommand{\rd}{\mathrm{d}}E(X)=\int_{1}^{\infty}x\frac{\rd F(x)}{\rd x}\rd x=\alpha\int_{1}^{\infty}x^{-\alpha} \rd x$$</p> <p>And this last expression shows that for $E(X)$ to exist, we must have $-\alpha&lt;-1$, which in turn implies $\alpha&gt;1$. This can easily be extended to determine the values of $\alpha$ for which the $r$'th raw moment $E(X^{r})$ exists.</p> https://stats.stackexchange.com/questions/10159/-/13377#13377 69 Answer by Firefeather for Find expected value using CDF Firefeather https://stats.stackexchange.com/users/1583 2011-07-22T15:30:25Z 2011-07-22T15:30:25Z <h1>Usage of the density function is not necessary</h1> <h2>Integrate 1 minus the CDF</h2> <p>When you have a random variable $X$ that has a support that is non-negative (that is, the variable has nonzero density/probability for only positive values), you can use the following property:</p> <p>$$E(X) = \int_0^\infty \left( 1 - F_X(x) \right) \,\mathrm{d}x$$</p> <p>A similar property applies in the case of a discrete random variable.</p> <h2>Proof</h2> <p>Since $1 - F_X(x) = P(X\geq x) = \int_x^\infty f_X(t) \,\mathrm{d}t$,</p> <p>$$\int_0^\infty \left( 1 - F_X(x) \right) \,\mathrm{d}x = \int_0^\infty P(X\geq x) \,\mathrm{d}x = \int_0^\infty \int_x^\infty f_X(t) \,\mathrm{d}t \mathrm{d}x$$</p> <p>Then change the order of integration:</p> <p>$$= \int_0^\infty \int_0^t f_X(t) \,\mathrm{d}x \mathrm{d}t = \int_0^\infty \left[xf_X(t)\right]_0^t \,\mathrm{d}t = \int_0^\infty t f_X(t) \,\mathrm{d}t$$</p> <p>Recognizing that $t$ is a dummy variable, or taking the simple substitution $t=x$ and $\mathrm{d}t = \mathrm{d}x$,</p> <p>$$= \int_0^\infty x f_X(x) \,\mathrm{d}x = \mathrm{E}(X)$$</p> <h2>Attribution</h2> <p>I used the <a href="http://en.wikipedia.org/wiki/Expected_value#Formulas_for_special_cases">Formulas for special cases</a> section of the <a href="http://en.wikipedia.org/wiki/Expected_value">Expected value</a> article on <a href="http://en.wikipedia.org">Wikipedia</a> to refresh my memory on the proof. That section also contains proofs for the discrete random variable case and also for the case that no density function exists.</p> https://stats.stackexchange.com/questions/10159/-/307220#307220 11 Answer by StijnDeVuyst for Find expected value using CDF StijnDeVuyst https://stats.stackexchange.com/users/71524 2017-10-10T15:09:29Z 2017-10-10T15:09:29Z <p>The result extends to the $k$th moment of $X$ as well. Here is a graphical representation: <a href="https://i.stack.imgur.com/FsuCH.png" rel="noreferrer"><img src="https://i.stack.imgur.com/FsuCH.png" alt="enter image description here"></a></p> https://stats.stackexchange.com/questions/10159/-/424361#424361 0 Answer by chirag nagpal for Find expected value using CDF chirag nagpal https://stats.stackexchange.com/users/257731 2019-08-30T18:27:13Z 2019-08-31T04:08:54Z <p>The Answer requiring change of order is unnecessarily ugly. Here's a more elegant 2 line proof.</p> <p><span class="math-container">$\int udv = uv - \int vdu$</span> </p> <p>Now take <span class="math-container">$du = dx$</span> and <span class="math-container">$v = 1- F(x)$</span></p> <p><span class="math-container">$\int_{0}^{\infty} [ 1- F(x)] dx = [x(1-F(x)) ]_{0}^{\infty} + \int_{0}^{\infty} x f(x)dx$</span></p> <p><span class="math-container">$= 0 + \int_{0}^{\infty} x f(x)dx$</span></p> <p><span class="math-container">$= \mathbb{E}[X] \qquad \blacksquare$</span></p>