Statalist The Stata Listserver

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

st: RE: balancing panel data & plotting R squared

From   "Nick Cox" <>
To   <>
Subject   st: RE: balancing panel data & plotting R squared
Date   Wed, 16 May 2007 12:48:45 +0100

Suppose your panelid is -id- and that you have
annual data for each of 10 years. Then 

bysort id : keep if _N == 10 

keeps only complete panels. 

Otherwise, see -help statsby-. 


> does anyone of you know how to balance panel data keeping 
> only the individuals 
> with observations in all the years?
> Further, is there a way of plotting the R squared (of separate annual 
> regressions) against the years, without copying the R values 
> by hand to 
> generate a new variable?

*   For searches and help try:

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