Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [covariance]

Questions about covariance, a measure of (linear) association between two random variables.

0
votes
0answers
5 views

what is the covariance matrix of 4x2 data points?

I do not know how to calculate the covariance matrix for a 4x2 data points The points are as followed: X | Y -2 | -1 -1 | 0 1 | 0 2 | 1 Can I get some ...
0
votes
0answers
10 views

Rank-1 modification of correlation matrix

I inherited a problem at work and have trouble wrapping my head around it. It doesn't help I'm insufficiently sophisticated with linalg. Help with or pointing to appropriate literature will be much ...
2
votes
1answer
59 views

Prove that $\operatorname{Cov}[X,E(Y|X)]=\operatorname{Cov}[X,Y]$

How can I prove that $\newcommand\cov{\operatorname{Cov}}\cov[X,E(Y|X)]=\cov[X,Y]$? I tried $\cov[X,E(Y|X)] = E[XE(Y|X)]-E(X)E[E(Y|X)] = E[XE(Y|X)]-E(X)E(Y)$ then I am stuck. How can $E[XE(Y|X)] = E(...
0
votes
0answers
15 views

Covariance of time-integrated processes with non-zero expectation

my ultimate goal is to compute the auto-covariance of the time-integrated Ornstein-Uhlenbeck process which has an initial value that is drawn from a Gaussian distribution with the same variance as the ...
0
votes
1answer
23 views

“Normalized” covariance matrix of a Gaussian random vector

Let $X\sim\mathcal{N}(0,I_{d})$. I would like to compute the the following quantity: \begin{equation} \mathbb{E}\bigg[\frac{XX^{\top}}{\|X\|_{2}^{2}}\bigg]. \end{equation} Letting $B=\frac{XX^{\top}}{...
0
votes
0answers
23 views

Given that $X_{i+1} = \rho X_{i}$, determine the dispersion matrix $Var[\textbf{X}]$

If $X_{1},X_{2},\ldots,X_{n}$ are random variables and $X_{i+1} = \rho X_{i}$ $(i = 1,2,\ldots,n)$, where $\rho$ is constant, and $\mathrm{Var}[X_1] = \sigma^2$, find $\mathrm{Var}[X]$. MY ATTEMPT ...
1
vote
0answers
17 views

Distribution/Variance of correlated squared normal random variables

If $X_{1}, X_{2}, \ldots, X_{N}$ are identically distributed normal random variables with mean $0$ and variance $\frac{(N+3)D\sigma^{2}}{N}$, then I want to calculate the distribution, or at least the ...
0
votes
2answers
216 views

Covariance of Geometric Distribution and Negative Binomial Distribution

Let independents $X_1,...X_n \thicksim \text{Bernoulli}(1,p)$ and $W_r$ refer to total number of trial until the $r$-th success, which means $W_r \thicksim \text{NegBin}(r,p)$ then I need to evaluate $...
0
votes
0answers
14 views

Handling negative variances on the derivative of Gaussian processes

The variance of the derivative of a Gaussian process, $f$, is given by (9.1): $$ Var(\frac{\partial f}{\partial x}) =\frac {\partial ^2 k(x,x)}{\partial x^2},$$ where $k(·, ·)$ is both a positive-...
0
votes
0answers
16 views

Under what conditions is an arbitrary matrix $A$ the covariance matrix of a column vector of random variables?

Let $X = \begin{bmatrix} X_1 & X_2 & \dots& \ X_n \end{bmatrix} ^{T} $ be an arbitrary column vector of random variables. Given an $n \times n$ matrix $A$, how do I determine whether ...
0
votes
1answer
24 views

Null covariance between X and Y: non-linear relationship between them

Let us consider a variable X with values $\{-1,1\}$, and another one Y with values $\{-2,-1,1,2\}$. X and Y have the following joint probability function $P(x,y)$: From this table, the covariance is ...
-3
votes
2answers
187 views

Eigenvalues and Eigenvectors of a singular Covariance matrix

I am working on a research in which my data matrix $\bf X$ has dimension of $N\times P$ where $P>>>>N$.ie. its a small sample size problem. I need to compute the covariance of $\bf X$, ...
1
vote
1answer
112 views

Ellipsoidal Covariance Matrix

What does it mean when you say "Covariance matrix are highly ellipsoidal"? I am reading Regularized Discriminant Analysis" by Jerome H. Friedman 1989 and it uses this term very often "Covariance ...
1
vote
1answer
666 views

Find the covaraince of the number of hearts drawn and the number of clubs drawn from a deck of cards.

Two cards are drawn without replacement from a pack of cards. The random variable $X$ measures the number of heart cards drawn, and the random variable $Y$ measures the number of club cards drawn. ...
0
votes
2answers
19 views

Is covariance transitive?

If given: $$cov(x, y) = 0, cov(x, z) = 0$$ then can we conclude that: $$cov(y, z) = 0$$
0
votes
0answers
10 views

Estimation of loading using Principal Component Analysis (Factor Analysis Approach)

i found one good documentation(by good i meant easy) about factor Analysis Factor Analysis i am following steps, but could not reach every step, so i will try to implement step by step ...
1
vote
1answer
718 views

Variance of residuals from simple linear regression

I am trying to compute $Var(e_i)$. So far I have $Var(e_i)=Var(y_i-\hat y_i)=Var(y_i)+Var(\hat y_i)-2cov(y_i,\hat y_i)$ Now, I know that $Cov(y_i,\hat y_i)=var(\hat y_i)$ but how do I prove ...
0
votes
0answers
13 views

Variance from the covariance matrix

I was reading about Common Spatial Pattern. The CSP algorithm tries to find the vector $w^T$ that maximises the ratio of variance between two windows $X_1$ of size $(n,t_1)$ and $X_2$ of size $(n,...
0
votes
1answer
19 views

Show diagonal covariance does not guarantee independence.

I was trying to show that if two variables have diagonal covariance, this does not necessarily guarantee their independence. For this, I was using an example where $x \sim U(-1,1)$ and $y=X^{2}$ to ...
0
votes
0answers
19 views

error covariance of MMSE estimator relation to other error covariance estimators

I'm trying to prove the following: let $ \Lambda_{e}$ be the error covariance of an estimator $\,\hat{\theta}(y)$ of $\,\theta$ based on $\,y$. I want to show that the error covariance of MMSE ...
0
votes
1answer
72 views

Log det of covariance and entropy

I understand log of determinant of covariance matrix bounds entropy for gaussian distributed data. Is this the case for non gaussian data as well and if so, why? What does Determinant of Covariance ...
1
vote
1answer
152 views

Transformation of a valid covariance matrix

Suppose we have a normally distributed random variable $\boldsymbol{X}$ with covariance matrix $\Sigma$, which is symmetric positive definite. Now if I multiply $\boldsymbol{X}$ by some matrix A, the ...
-1
votes
0answers
9 views

Determinants of the covariance between two random variables

I want to know if the covariance between two random variables is always determined by the two terms of its formula or if it can be only determined by the E(XY). If E(Y)=0, then Cov(X,Y)=E(XY)-E(X)E(Y)...
0
votes
1answer
26 views

Given two random vectors, determine the dispersion matrix $Var[\textbf{X}]$.

Let $\textbf{X} = (X_{1},X_{2},\ldots,X_{n})^{\prime}$ be a vector of random variables, and let $Y_{1} = X_{1}$ and $Y_{i} = X_{i}-X_{i-1}$ where $i = 2,3,\ldots,n$. If $Y_{i}$ are mutually ...
1
vote
0answers
29 views

Calculate covariance given correlation, problem with percentages

The question is: find the covariance of ABC stock returns with the original portfolio returns. Pretty straightforward. However I get confused working between percentages and units. The ...
2
votes
2answers
707 views

Covariance of Martingales

I have proven that Martingales have orthogonal increments. From this I need to show that $\operatorname{Cov}[M(t),M(s)]$ relies only on $\min\{s,t\}$. I used the expected value definition of ...
1
vote
1answer
42 views

Covariance matrix of uniform distribution in $L^p$ Euclidean ball [closed]

Let $$X=\operatorname{Unif}\left(\left\{x:\ \sum_{i=1}^n |x_i|^p\le 1\right\}\right)$$ Is there some method to calculate the covariance matrix of $X$? Thank you!
0
votes
1answer
14 views

truncation degree of decomposed covariance matrix

I have a covariance matrix of a standardized data set. Doing a singular value decomposition i find near zero singular values and would therefore like to truncate it. I know of Picard plots which ...
0
votes
0answers
34 views

Using Cholesky decomposition to compute covariance matrix determinant

I am reading through this paper to try and code the model myself. The specifics of the paper don't matter, however in the authors matlab code I noticed they use a Cholesky decomposition instead of ...
10
votes
1answer
113 views

Constructing a probability measure on the Hypercube with given moments

Let $H = [-1, 1]^d$ be the $d$-dimensional hypercube, and let $\mu \in \text{int} H$. Under these conditions, I can explicitly construct a tractable probability measure $P$, supported on on $H$, ...
1
vote
0answers
50 views

Covariance matrix and projection

I have troubles understanding a geometrical meaning of a covariance matrix. Let's say we have a data set containing two points (-1,1), (-1,2) and write them in to the matrix $$D = \begin{bmatrix} -...
0
votes
0answers
12 views

How to compute $cov(\frac{1}{2}Z'AZ,\frac{1}{2}Z'BZ)$?

I want to show that $cov(\frac{1}{2}\textbf{Z}'A\textbf{Z},\frac{1}{2}\textbf{Z}'B\textbf{Z})=\frac{1}{2}tr(AR(\theta)BR(\theta))$ where $A,B \in Sym(p)$ (real symmetric $p \times p$ matrices) and $\...
2
votes
1answer
59 views

Example of “The eigenvalues of data covariance matrix, $\Phi^T\Phi$ measure the curvature of the likelihood function.”

I am reading PRML, Chapter 3.5.3, screen shot attached. I can understand the derivation and maths but hard to understand the meaning of "The eigenvalues of data co-variance, $\Phi^T\Phi$ matrix ...
0
votes
0answers
46 views

Rank of covariance matrix

I am having a problem with rank deficiency in a covariance matrix. I have a data-set of M variables and N observations, M>N. Calculating the singular value decomposition of the data-sets covariance ...
1
vote
0answers
16 views

How to calculate $\text{cov}(\hat{Y}_{ij}, \hat{Y}_{kj})$ if $Y_{ij} = \mu + a_i + b_j + e_{ij}$?

Let's assume we have the model following Two-Factor model without replications : $$Y_{ij} = \mu + a_i + b_j + e_{ij}, \; i=1,\dots,p \; \text{and} \; j=1,\dots, q $$ I am interested in calculating ...
0
votes
1answer
15 views

Dimensional properties derived from PCA eigenvectors

Background Let's assume I'm using principal component analysis to carry out clustering of a 2-d data set, using a non-normalized covariance matrix to carry out the operation. I then solve for the ...
0
votes
0answers
20 views

Understanding Weird Relationship Between Hamming Weights

I have two binary "mapping" matrices $\delta_0$ and $\delta_1$ $ \delta_0 = \begin{bmatrix} 1 0 1 0 0 0 0 0\\ 1 1 0 1 1 1 1 0\\ 0 0 0 0 1 1 0 0\\ 0 1 1 1 0 0 0 0\\ 0 1 1 0 1 0 0 0\\ 1 0 0 1 1 1 0 0\...
2
votes
0answers
19 views

Covariance of errors $\text{cov}(\hat{e_{ij}},\hat{e_{i\ell}})$ in Two-Way Anova model

Exercise : Consider the Two-Way Anova model $Y_{ij} = \mu + a_i + b_j + e_{ij}$ with $i = 1, \dots, p$ and $j=1,\dots,q$. Show that : $$\text{cov}(\hat{e_{ij}},\hat{e_{i\ell}}) = -\sigma^2\left(\...
0
votes
1answer
26 views

Covariance of square root for two bins of a multinomial

Take $(X_1, \dots, X_k) \sim Multinomial(n, (p_1, \dots, p_k))$. Do we have a closed form expression for $\mathbb{E}[\sqrt{X_i X_j}], i\neq j$ ?
1
vote
1answer
766 views

Variance of $3$-dimensional vectors

I am currently optimizing some code and thus, I want to replace an inefficient OpenCV function, which calculates a covariance matrix. The thing is, that I only need the trace of this covariance matrix,...
0
votes
0answers
17 views

Normal Random Variables that all correlate with a single time series but not necessarily with each other

I have a sequence of normally distributed random variables. Let's call it $S_1$. I want to generate 4 more series, each of which has its own correlation with $S_1$ and its own variance. Let's call ...
0
votes
1answer
27 views

Finding $\text{Cov}(X,Y)$ when $(X,Y)$ has joint density $\frac{1}{2}\sin(x+y)\mathbf1_{0\le x,y\le\pi/2}$

Joint probability density: \begin{equation} P_{x,y}(x,y) \begin{cases} \frac{1}{2}\sin(x + y) & , \text{if}\ 0\leq x \leq \frac{\pi}{2}, 0 \leq y \leq \frac{\pi}{2} \\ 0 & ...
0
votes
0answers
12 views

Scalar product induced by covariance matrix

Suppose that $n$-dimensional random vector $Y$ has covariance matrix $\Sigma$. It is well known that for any $a\in\mathbb{R}^n$ we have \begin{align} var(a^TY)=a^T\Sigma a. \end{align} Is there any ...
0
votes
0answers
21 views

Variance and covariances from linear mixed model for power simulation using R

I am working with longitudinal data where the outcome is the number of steps per minute. My LMM fit would look like: ...
3
votes
0answers
117 views

Explicitly proving that the Hamiltonian is Lorentz covariant

I want to show explicitly that the Hamiltonian $$ H = -\Omega V + \int d\tilde{\textbf{k}}\ \omega (a^\dagger(\textbf{k}) a(\textbf{k}) + b(\textbf{k}) b^\dagger(\textbf{k}) ) $$ is Lorentz ...
0
votes
1answer
11 views

How to show that the error variance of the best linear predictor is inferior to the proportional predictor?

Let's consider the 1D case. How do we prove that the error variance of the Best Linear Predictor (BLP) is inferior than the Proportional Predictor (i.e. the Linear Predictor without the intercept)? ...
0
votes
1answer
867 views

need help to get $Cov(XY,Z)$

I have three variables X, Y, Z. and I know $Corr(X,Y), Corr(X,Z),Corr(Y,Z),Var(X),Var(Y),Var(Z)$. and Cov is Covariance, Corr is correlation, Var is variance, $Corr(X,Y)=\frac{Cov(X,Y)}{\sqrt{Var(X)*...
0
votes
1answer
19 views

Stretching the covariance of a daily change to the year

I'm diving into financial mathematics and have calculated a matrix that gives me the daily change of four given securities: The start of it looks like this: My Tutorial is now calculating the ...
1
vote
1answer
50 views

We have an urn with 6 red balls and 4 green balls.

We have an urn with 6 red balls and 4 green balls. We draw balls from the urn one by one without replacement, noting the order of the colors, until the urn is empty. Let X be the number of red balls ...
0
votes
0answers
5 views

Testing cross-covariance in the residuals of a VAR(p) model

Suppose I have a vector autoregressive model of order $p$: $$y_t = c + A_1 y_{t-1} + ... + A_p y_{t-p} + u_t$$, where $y_t$ is a $K\times 1$ vector and $A_i$ are $K\times K$ matrices. We assume the ...