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

st: Re: creating mean across panel variables

From   Kit Baum <>
Subject   st: Re: creating mean across panel variables
Date   Wed, 24 Oct 2007 07:04:04 -0400

-collapse- will create a dataset with one observation per day containing the summary statistics you specify. If you don't want to collapse the data, then -egen, mean()- will create a new variable with the same mean value repeated for each firm.

Kit Baum, Boston College Economics and DIW Berlin
An Introduction to Modern Econometrics Using Stata:

On Oct 24, 2007, at 2:33 AM, Thomas wrote:

I have the following problem I have been unable to decipher.  I have a
panel of 200 firms with 5 years of trading data in the form of spreads
at various maturity points.  Suppose I wish to create a daily average
or median spread across all firms to produce a time series of average
and mean each day.  Can anyone suggest how to do that?  Thanks.
*   For searches and help try:

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