Чи означає, що центрування зменшує коваріацію?


11

Якщо припустити, що у мене є дві незалежні випадкові величини, і я хочу максимально зменшити коваріацію між ними, не втрачаючи занадто багато "сигналу", чи означає центринг допомогу? Я десь читав, що середнє центрування зменшує кореляцію на значний фактор, тому я думаю, що це повинно зробити те ж саме для коваріації.

Відповіді:


30

Якщо X і Y - випадкові величини, а a і b - константи, то

Cov(X+a,Y+b)=E[(X+aE[X+a])(Y+bE[Y+b])]=E[(X+aE[X]E[a])(Y+bE[Y]E[b])]=E[(X+aE[X]a)(Y+bE[Y]b)]=E[(XE[X])(YE[Y])]=Cov(X,Y).
Центрування - це особливий випадокa=E[X]іb=E[Y], тому центрування не впливає на коваріацію.


Крім того, оскільки кореляція визначається як

Corr(X,Y)=Cov(X,Y)Var(X)Var(Y),
ми можемо бачити, що
Corr(X+a,Y+b)=Cov(X+a,Y+b)Var(X+a)Var(Y+b)=Cov(X,Y)Var(X)Var(Y),
тому, зокрема, на кореляцію не впливає і центрування.


Це була популяційна версія історії. Зразок версії такий же: Якщо ми використовуємо

Cov^(X,Y)=1ni=1n(Xi1nj=1nXj)(Yi1nj=1nYj)
як наша оцінка коваріації міжXіYз парного зразка(X1,Y1),,(Xn,Yn), то
Cov^(X+a,Y+b)=1ni=1n(Xi+a1nj=1n(Xj+a))(Yi+b1nj=1n(Yj+b))=1ni=1n(Xi+a1nj=1nXjnna)(Yi+b1nj=1nYjnnb)=1ni=1n(Xi1nj=1nXj)(Yi1nj=1nYj)=Cov^(X,Y)
for any a and b.


thanks for the detailed answer. Does it mean that for sample covariance the sample size doesn't have any impact either? i.e. reducing the sample size does not reduce the sample covariance?
lvdp

3
@lvdp That should probably be a separate question.
Acccumulation

A reduced sample size can only come with a different sample. A different sample could show different covariance, therefore. But as sample covariance is defined as an average, sample size is scaled for in principle.
Nick Cox

5

The definition of the covariance of X and Y is E[(XE[X])(YE[Y])]. The expression XE[X] in that formula is the centered version of X. So we already center X when we take the covariance, and centering is an idempotent operator; once a variable is centered, applying the centering process further times doesn't change it. If the formula didn't take the centered versions of the variables, then there would all sort of weird effects, such as the covariance between temperature and another variable being different depending on whether we measure temperature in Celsius or Kelvin.


3

"somewhere" tends to be a rather unreliable source...

Covariance/correlation are defined with explicit centering. If you don't center the data, then you are not computing covariance/correlation. (Precisely: Pearson correlation)

The main difference is whether you center based on a theoretical model (e.g., the expected value is supposed to be exactly 0) or based on the data (arithmetic mean). It is easy to see that the arithmetic mean will yield smaller Covariance than any different center.

However, smaller covariance does not imply smaller correlation, or the opposite. Assume that we have data X=(1,2) and Y=(2,1). It is easy to see that with arithmetic mean centering this will yield perfectly negative correlation, while if we know the generating process produces 0 on average, the data is actually positively correlated. So in this example, we are centering - but with the theoretical expected value of 0.

This can arise easily. Consider we have a sensor array, 11x11, with the cells numbered -5 to +5. Rather than taking the arithmetic mean, it does make sense to use the "physical" mean of our sensor array here when looking for the correlation of sensor events (if we enumerated the cells 0 to 10, we'd use 5 as fixed mean, and we would get the exact same results, so that indexing choice disappears from the analysis - nice).


Thanks @Anony-Mousse, will the sample covariance depend on the sample size? I.e. smaller sample size will yield smaller covariance ( before centering).
lvdp

1
Depends on the sample obviously. On average - I don't know. I'd expect smaller samples to have more variability mostly, so maybe more often more extreme values. But that is just an intuition.
Has QUIT--Anony-Mousse
Використовуючи наш веб-сайт, ви визнаєте, що прочитали та зрозуміли наші Політику щодо файлів cookie та Політику конфіденційності.
Licensed under cc by-sa 3.0 with attribution required.