# 统计代写| Variance stat代写

## 统计代考

4.6 Variance
One important application of LOTUS is for finding the variance of a random variable. Like expected value, variance is a single-number summary of the distribution of a random variable. While the expected value tells us the center of mass of a distribution, the variance tells us how spread out the distribution is.
Definition 4.6.1 (Variance and standard deviation). The variance of an r.v. $X$ is
$$\operatorname{Var}(X)=E(X-E X)^{2} .$$
172
The square root of the variance is called the standard deviation (SD):
$$\operatorname{SD}(X)=\sqrt{\operatorname{Var}(X)} .$$
Recall that when we write $E(X-E X)^{2}$, we mean the expectation of the randon variable $(X-E X)^{2}, \operatorname{not}(E(X-E X))^{2}$ (which is 0 by linearity).

The variance of $X$ measures how far $X$ is from its mean on average, but instead of simply taking the average difference between $X$ and its mean $E X$, we take the average squared difference. To see why, note that the average deviation from the mean, $E(X-E X)$, always equals 0 by linearity; positive and negative deviations cancel each other out. By squaring the deviations, we ensure that both positive and is an average squared distance, it has the wrong units: if $X$ is in dollars, $\operatorname{Var}(X)$ is
in squared dollars. To get back to our original units, we take the square root; this gives us the standard deviation.

One might wonder why variance isn’t defined as $E|X-E X|$, which would achieve the goal of counting both positive and negative deviations while maintaining the same units as $X$. This measure of variability isn’t nearly as popular as $E(X-E X)^{2}$, for a variety of reasons. Most notably, the absolute value function isn’t differentiable various fundamental mathematical results such as the Pythagorean theorem.
An equivalent expression for variance is $\operatorname{Var}(X)=E\left(X^{2}\right)-(E X)^{2}$. This formula is often easier to work with when doing actual calculations. Since this is the variance formula we will use over and over again, we state it as its own theorem.
Theorem 4.6.2. For any r.v. $X$,
$$\operatorname{Var}(X)=E\left(X^{2}\right)-(E X)^{2}$$
Proof. Let $\mu=E X$. Expanding $(X-\mu)^{2}$ and using linearity, the variance of $X$ is
$$E(X-\mu)^{2}=E\left(X^{2}-2 \mu X+\mu^{2}\right)=E\left(X^{2}\right)-2 \mu E X+\mu^{2}=E\left(X^{2}\right)-\mu^{2} .$$
Variance has the following properties. The first two are easily verified from the definition, the third will be addressed in a later chapter, and the last one is proven just after stating it.

• $\operatorname{Var}(X+c)=\operatorname{Var}(X)$ for any constant $c$. Intuitively, if we shift a distribution to the left or right, that should affect the center of mass of the distribution but not its spread.
• $\operatorname{Var}(c X)=c^{2} \operatorname{Var}(X)$ for any constant $c$. this and discuss it more in Chapter $7 .$ This is not true in general if $X$ and $Y$ are $\operatorname{Var}(X+Y)=\operatorname{Var}(2 X)=4 \operatorname{Var}(X)>2 \operatorname{Var}(X)=\operatorname{Var}(X)+\operatorname{Var}(Y)$

## 统计代考

4.6 差异
LOTUS 的一项重要应用是寻找随机变量的方差。与期望值一样，方差是随机变量分布的单数汇总。期望值告诉我们分布的质心，而方差告诉我们分布的分散程度。

$$\operatorname{Var}(X)=E(X-E X)^{2} 。$$
172

$$\operatorname{SD}(X)=\sqrt{\operatorname{Var}(X)} 。$$

$X$ 的方差衡量 $X$ 与其平均值的平均距离，但我们不是简单地取 $X$ 与其平均值 $E X$ 之间的平均差，而是取平均平方差。要了解原因，请注意与平均值的平均偏差 $E(X-E X)$ 在线性度上总是等于 0；正负偏差相互抵消。通过对偏差进行平方，我们确保了正数和均方距离的单位错误：如果 $X$ 以美元为单位，则 $\operatorname{Var}(X)$ 是

$$\operatorname{Var}(X)=E\left(X^{2}\right)-(E X)^{2}$$

$$E(X-\mu)^{2}=E\left(X^{2}-2 \mu X+\mu^{2}\right)=E\left(X^{2}\right)-2 \mu E X+\mu^{2}=E\left(X^{2}\right)-\mu^{2} 。$$

• 对于任何常数 $c$，$\operatorname{Var}(X+c)=\operatorname{Var}(X)$。直观地说，如果我们将分布向左或向右移动，那应该会影响分布的质心，但不会影响分布。
• 对于任何常数 $c$，$\operatorname{Var}(c X)=c^{2} \operatorname{Var}(X)$。这个并在第 7 章中讨论它。$如果$X$和$Y$是$\operatorname{Var}(X+Y)=\operatorname{Var}(2 X)=4 \operatorname，这通常是不正确的{Var}(X)>2 \operatorname{Var}(X)=\operatorname{Var}(X)+\operatorname{Var}(Y)\$