
From  Scott Cunningham <scunning@gmail.com> 
To  statalist@hsphsun2.harvard.edu 
Subject  Re: st: linear interpolation 
Date  Tue, 25 Jul 2006 16:23:57 0400 
Rafal,
I know I need to expand by 31,815 observations (1761 for every year in the 1980s and 1774 for every year in the 1990s).
. local N = `_N' + 31815
. set obs `N'
obs was 5318, now 31815
What I'm trying to figure out now is to assign values of a year for every 1761 observations through the 1980s, then 1774 for every year in the 1990s. For instance, to do this:
year
1981
1981
...
1981
(where the total is 1,761 for 1981, and the same would be for 8289, and 1774 per year for 19911999). I don't think using what you wrote, ". replace year=1975 + _n if year==." will work since I do not need year increasing with every observation. Does anyone know how to fill in missing data with such precision?
sc
*
* 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/
* * 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–2021 StataCorp LLC  Terms of use  Privacy  Contact us  What's new  Site index 