Statalist The Stata Listserver


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: sum of covariances


From   "Olga Gorbachev Melloni" <olga_gorbachev@hotmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   st: sum of covariances
Date   Wed, 20 Sep 2006 16:04:07 -0400

Dear Statalist,

I am trying to compute sum of covariances between groups on a panel dataset.

Specifically, I have panel data on individual consumption (Cit) and demographic info.

I would like to know what the sum of covariances is for group i vs. group j over a particular time period. So my varcov matrix is not cross sectional but over time series, and I am computing

Cov(Cit,Cjt)=sum(Cit-Ci)(Cjt-Cj) , where Ci or Cj are means for for i or j over t


Is there a way to do it in Stata?


*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/




© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index