Now I see it can't hold. Thank you for the counter examples... You guys rule!

Thank you very much for your comments!

I added, however, some observations that were missing. Most importantly is the fact that we can assume that there exist a positive covariance between X and Y.

At first, it seemed to me that it would be easy to demonstrate... but I still did not manage to solve this problem. Can you guys give me a hand?

Suppose we make use of

$\mathbf{i)}$ a time series $X = [x_1,...,x_N]$ containing only positive entries (i.e. $0 \leq x_i$ for all $i$),

$\mathbf{ii)}$ a vector of weights of the same of length given by $Y = [y_1,...,y_N]$ where $0 \leq y_i \leq 1$ for all $i$

to build

$\mathbf{iii)}$ a time series $Z = [z_1,...,z_N]$, where the $i$th term is given by $z_i = x_i y_i$, i.e., $Z = [x_1 y_1,...,x_N y_N]$. Clearly, as $Y \in [0,1]$, we have that $0 \leq Z \leq X$ for all $i$.

$\mathbf{Question)}$ Can we demonstrate that $\text{var}(Z) \leq \text{var}(X)$?

For example, if

$X = [2, 6, 99, 12, 3, 1]$ and $Y = [0.34, 0.01, 0.2, 1, 0.3, 0.17]$, we have

$ Z = [x_1 y_1,...,x_N y_N] = [0.68, 0.06, 19.8, 12, 0.9, 0.17]$

$ \widehat{\sigma}^{2}_{X} = 1494.70$

$ \widehat{\sigma}^{2}_{Z} = 69.81$

$\mathbf{Important} \text{ } \mathbf{observations}$:

1) $X$ and $Y$ are stationary, ergodic random processes

2) $X$ is not a constant time series, in a sense that $\text{var}(X) \geq 0$

3) It can be assumed that $\text{var}(X) \geq \text{var}(Y) \geq 0$

4) There exist a positive covariance $X$ between and $Y$

  • Possible implication of 4)?

As $0 \leq Z \leq X$, we could define a given time series $W \geq 0$ such as $Z + W = X$. Thus, $\text{var}(X) = \text{var}(Z + W) = \text{var}(Z) + \text{var}(W) + 2\text{cov}(Z,W)$. Note that if $\text{cov}(Z,W) \geq 0$ then $\text{var}(X) \geq \text{var}(Z)$ because $\text{var}(W)$ is also greater than zero.

Does the fact that $\text{cov}(X,Y) \geq 0$ infer that $\text{cov}(Z,W) \geq 0$? There is any condition that guarantees $\text{cov}(Z,W) > 0$

Why I was so convinced about $\text{var}(Z) \leq \text{var}(X)$?

In the application I am interested in, I have observed that the relation $\text{var}(Z) \leq \text{var}(X)$ is attended at every time I run my algorithm. If I cannot demonstrate that $\text{var}(Z) \leq \text{var}(X)$ holds given the observations 1) to 4), I would like to know what is forcing that relation, like, for example, $\text{cov}(Z,W) \geq 0$ as mentioned above.

Thanks again for the replies!


  • 2
    $\begingroup$ Here's a hint for the general question: consider $a=10$ with probability one, so a constant variable, and $b$ uniform on, say, [0,1]. Note however that although this answers your general question, it does not answer your main question since Z and X are dependent. $\endgroup$
    – KOE
    Jul 21, 2014 at 5:52
  • $\begingroup$ The notation is unclear on your specific question. How is X defined? It looks to me as if X is both a vector of numbers (N realizations of some random variable?) and a random variable (you are asking for $var(X)$). $\endgroup$
    – KOE
    Jul 21, 2014 at 6:23
  • $\begingroup$ How does your first "observation" (that $X$ is not constant) follow from your assumptions? I don't see how it does. Indeed, assume that $X=1$ is constant, then of course your conclusion does not follow. Or if you add the assumption that $X$ is nonconstant, then you can have it fluctuate a tiny little bit around 1, as in Alexis' answer, and your conclusion again does not follow. $\endgroup$ Jul 21, 2014 at 6:58
  • $\begingroup$ I see that it was not clear enough. $\endgroup$
    – Dabaso
    Jul 21, 2014 at 16:59
  • $\begingroup$ Thanks for your observation! I see it can be more clear: i) X is a stochastic process for which we have N observations (see i.imgur.com/YhILAj3.png) ii) X can be assumed to be stationary and ergodic iii) There exists a positive covariance between X and Y (it can be important, I forgot to mention) iv) "a" and "b" are random variables. I will add this extra observations above in the description of the problem thanks again $\endgroup$
    – Dabaso
    Jul 21, 2014 at 17:14

5 Answers 5


Clearly not.

An easy counterexample (here done in R), that I think satisfies all your constraints:

[1] 0.8413043
[1] 0.2425253
[1] 2425.296

What's going on:

  1. x is a series with mean 100 and sd 1.

  2. y alternates between 0.01 and 0.99.

  3. z=xy therefore alternates between (about) 1 and 99, but is always $<x$

Alternative [more general] question) Assuming finite variances, is it true that for any random variable a and b such that 0≤a≤b, we have var(a)≤var(b)?

Even more clearly not; without the need for a "y" like variable, it's pretty obvious:

Consider one set of values that alternates between 1 and 99, and a second one that alternates between 100 and 101.

Adding in the new condition that X and Y have positive covariance:

 x = oldx + y  # oldX and Y are independent, so X and Y now have +ve covariance
[1] 0.2739745  # sample covariance happens to be positive in this case also
[1] 1.065326
[1] 0.2425253
[1] 2481.243

If you work out the answers for this case algebraically (compute the population variances and relevant population covariance), you'll see this isn't just a numerical accident from a fortunate choice of seed.

  • $\begingroup$ Hello Glen_b! I see now that for the more general case it can't hold. But for my original question, I forgot to mention that X and Y are not independent. In fact we should have cov(X,Y) > 0. I will write a detailed example above. Thank you very much for your comment! $\endgroup$
    – Dabaso
    Jul 21, 2014 at 17:35
  • 1
    $\begingroup$ Having X and Y with positive covariance will not help. See the new example in my answer (a tiny modification of the old one). If you wish to modify the circumstances again, I suggest a new question. $\endgroup$
    – Glen_b
    Jul 21, 2014 at 22:06
  • $\begingroup$ +1. You don't even need to generate oldx. Try this: z<-(x<-1+(y<-runif(100)))*y; var(z)/var(x); cor(x,y). $\endgroup$
    – whuber
    Jul 21, 2014 at 22:19
  • 1
    $\begingroup$ @whuber Thanks - indeed I saw there would be simpler examples of this new case, but I wanted to show the OP that it was already clear from my previous example that making the covariance positive wouldn't help. I decided that showing a tiny modification of that case might serve to highlight that. I think it's nice that there are so many counterexamples presented; the different approaches to identifying counterexamples in the answers make this more instructive than the question would indicate. $\endgroup$
    – Glen_b
    Jul 21, 2014 at 22:25
  • $\begingroup$ Now I see it can't hold. Thank you for the counter examples... You guys rule! $\endgroup$
    – Dabaso
    Jul 22, 2014 at 5:15

I do not think Var$(Z)\le $Var$(X)$. Imagine that $X$ is a time series that meanders about values near 100, almost always between 98 and 102. Now imagine that $Z$ meanders between 0 and 100, but is always less than $X$. The variance of $Z$ is clearly going to be larger in such a case than the variance of $X$. This is an example where $X$ and $Z$ are stationary around some constants, but it could easily be extended to a trend stationary example... I am not sure if it would extend to integrated time series... need to think on that.

  • $\begingroup$ Hi Alexis! Thanks for your comment. I see your point: Of course, the dispersion of $Z$ around $\mu_Z$ can be greater than the dispersion of $X$ around $\mu_X$ regardless if $Z \leq X$. However, there is an important point that I forgot to mention: $\text{cov}(X,Y) > 0$. Does the fact that this positive covariance should hold imply that the weighted signal $Z$ should have $\text{var}(Z) \leq \text{var}(X)$? I will try to make it clear in my original question above. Thanks again! $\endgroup$
    – Dabaso
    Jul 21, 2014 at 17:43
  • 1
    $\begingroup$ The answer is still no. $\endgroup$
    – Alexis
    Jul 21, 2014 at 18:01

For the general case, the answer is no. For the specific cases, it is also no.

A simple counter example is take $ y\sim U (0,1) $ and take $ x\sim Gamma (a, a) $ such that we have $ E (x)=1 $ and $ var (x)=a^{-1}$ . Take $ x $ and $ y $ as independent, and we have:

$$ var (z) =E [var (z|y)]+var [E (z|y)]=E [y^2a^{-1}]+var [y]=var (y) + E (y^2)a^{-1}=\frac {1}{12} +\frac {1}{3} var (x)=var (x)\frac {a+4}{12} $$

Now we just choose any value for $ a $ such that $ a> 8$ and we will have $ var (z)> var (x) $

  • $\begingroup$ Hello! Thank you very much for your comment! Unfortunately (or not), $x$ and $y$ are not indepedent. I added this extra information in my original question above. For the general case for $a$ and $b$, however, I see it can't hold. $\endgroup$
    – Dabaso
    Jul 21, 2014 at 17:31

Let us be clear that the "variance" under discussion appears to be a random variable derived from a finite portion of a time series. Specifically, the raw $k^\text{th}$ moment of $\mathrm{X} =(X_1, X_2, \ldots, X_N)$ is

$$\mu_k(\mathrm{X}) = (X_1^k+X_2^k+\cdots+X_N^k)/N,$$

which is a random variable, and the variance is

$$\text{var}(\mathrm{X}) = \mu_2(\mathrm{X}) - \mu_1^2(\mathrm{X}),$$

which also is a random variable.

Similarly we may define moments $\mu_{jk}$ of the bivariate series $(X_i,Y_i)$ and from those compute a covariance. All these definitions make sense even when either series is constant (although then the moments and variance may reduce to numbers rather than random variables).

To show that counterexamples exist even when $X$ and $Y$ have positive covariance, let the $Y_i$ be bounded by $0$ and $1$, let $\mathrm{Y}$ have nonzero variance, pick $0 \lt \varepsilon \lt 1$, and define

$$X_i = 1 + \varepsilon Y_i \ge 0.$$

By construction there is perfect (unit) correlation between each $X_i$ and $Y_i$ as well as between $\mu_k(\mathrm{X})$ and $\mu_k(\mathrm{Y})$ for any $k\gt 0$; certainly the covariances are positive.

Yet, since $Z_i=X_iY_i = Y_i + \varepsilon Y_i^2$,

$$\text{Var}(\mathrm{Z}) = \text{Var}(\mathrm{Y}) + 2\varepsilon\mu_1(\mathrm{Y}^3) + \varepsilon^2 \mu_1(\mathrm{Y}^4) \gt \text{Var}(\mathrm{Y}) \gt \varepsilon^2 \text{Var}(\mathrm{Y}) = \text{Var}(\mathrm{X}),$$

disproving the conjecture in the question.

The same analysis (coupled with the fact that $\mu_1(\mathrm{Y}^4)\lt \mu_1(\mathrm{Y}^2)$) demonstrates that for sufficiently large $\varepsilon\gt 1$, the inequality must be reversed. Thus there is no necessary inequality relating $\text{Var}(\mathrm{X})$ and $\text{Var}(\mathrm{Z})$.


Assume that the processes $\{X\}$ and $\{Y\}$ are ergodic/stationary with finite moments, and independent. Then $\{XY\}$ is also ergodic and

$$\operatorname{Var(XY)} = E(X^2Y^2) - [E(XY)]^2 = E(X^2)E(Y^2) - [E(X)]^2[E(Y)]^2$$

the break-up of expected values due to independence.

You are asking

$$E(X^2)E(Y^2) - [E(X)]^2[E(Y)]^2 \leq E(X^2) - [E(X)]^2\;\;??$$

$$\Rightarrow [E(X)]^2\cdot [1-[E(Y)]^2] \leq E(X^2)\cdot [1-E(Y^2)]\;\; ?? \qquad[1]$$

Since $0\leq Y \leq 1$ we have

$$0\leq E(Y) \leq 1 \Rightarrow 0\leq [E(Y)]^2 \leq1,\;\; 0\leq E(Y^2) \leq1$$

and also

$$E(Y^2) > [E(Y)]^2 \Rightarrow [1-[E(Y)]^2] > [1-E(Y^2)] \qquad[2]$$

Examining the desired inequality $[1]$ and the true inequality $[2]$ one sees that $[1]$ may or may not hold, since $[E(X)]^2 < E(X^2)$.

I would say this is an instructive example of how things change when we move from a deterministic to a stochastic assumption - because if the $y_i$'s are designated as a deterministic sequence, then of course the variance of $X_iy_i$ is no greater than the variance of $X_i$.

  • $\begingroup$ Either you are changing what you mean by "variance" or else somewhere you seem to have overlooked the basic idea communicated in the counterexamples posted in other answers. In the final paragraph, let the $X_i$ have a mean of $1$ and a tiny variance. Letting the $y_i$ alternate between $0$ and $1$ will make the variance of $X_iy_i$ larger than that of the $X_i$ alone. $\endgroup$
    – whuber
    Jul 21, 2014 at 14:44
  • $\begingroup$ @whuber. If the $y_i$'s are deterministic, doesn't it hold that $\operatorname{Var}(y_iX_i)= y_i^2\operatorname{Var}(X_i)$? In which case, if $y_i=0$ then $\operatorname{Var}(0\cdot X_i)=0 < \operatorname{Var}(X_i)$ while if $y_i=1$, then $\operatorname{Var}(y_iX_i)= \operatorname{Var}(X_i)$ ? (I also changed "smaller" to "no greater than") $\endgroup$ Jul 21, 2014 at 14:53
  • $\begingroup$ What I'm struggling to understand are the intended meanings of "variance" in your remarks. Your comment refers to the variance of a single random variable $X_i$ (with $i$ fixed), whereas I had understood the question to refer to the variances of sequences $(X_1, X_2, \ldots, X_N)$ extracted from time series. (See the example calculations at the end of the question.) $\endgroup$
    – whuber
    Jul 21, 2014 at 15:02
  • 1
    $\begingroup$ @whuber hmmm... with $y_i$'s deterministic, the process $y_iX_i$ is no longer ergodic (or stationary). So "time averages" of moments do not coincide with "ensemble moments". So it appears my answer is tailored (and constrained) by its own assumptions. $\endgroup$ Jul 21, 2014 at 15:46
  • 1
    $\begingroup$ Well, that's new information. $\endgroup$ Jul 21, 2014 at 19:08

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.