Statalist


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

st: RE: r(451)


From   Alan Williamson <[email protected]>
To   [email protected]
Subject   st: RE: r(451)
Date   Tue, 21 Aug 2007 09:46:55 +0000

Thank you so much. It is very helpful.

Alan


With this dataset, -n- is not a valid identifier. 
I don't know what it is, but 

. su n

    Variable |       Obs        Mean    Std. Dev.       Min        Max
-------------+--------------------------------------------------------
           n |      1031    1.056002    1.341506  -2.263364   4.687321

shows that it's not acceptable as an identifier.

Your command 

. gen yr=y(1980)+_n-1,
options not allowed
r(101);

is failing because Stata sees the comma and -- as it is 
telling you -- options are not allowed with -generate-, but the command 
will fail anyway because y(1980) is not legal Stata. 

I don't know anything about this dataset, but my guess
is that -id- is a suitable identifier. 

Nick 
[email protected] 

Alan Williamson
 
> I use stata-press data of abdata to run xtabond. But I got 
> message like:
> 
> . use http://stata-press.com/data/r9/abdata
> 
> . tis year
> 
> . iis n
> 
> . tsset n year
> repeated time values within panel
> r(451);
> 
> . gen yr=y(1980)+_n-1,
> options not allowed
> r(101);
> 
> . gen yr=year
> 
> . tsset n yr
> repeated time values within panel
> r(451);
> 
> In this case,  are there any suggestions about how can I set 
> the tsset properly for n m ys etc. please?

*
*   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/


_________________________________________________________________
Try Live.com - your fast, personalised homepage with all the things you care about in one place.
http://www.live.com/?mkt=en-gb  

*
*   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–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index