Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: RE: Can't Read "00020" as a Character in Stata?


From   "Nick Cox" <n.j.cox@durham.ac.uk>
To   <statalist@hsphsun2.harvard.edu>
Subject   st: RE: Can't Read "00020" as a Character in Stata?
Date   Wed, 29 Jun 2005 22:07:49 +0100

You must spell out that you want the id read 
as a string variable. The help includes examples. 

Nick 
n.j.cox@durham.ac.uk 

Nomorenook@netscape.net
 
> I encounter a data input problem in Stata. I have a fixed 
> format file, i.e., abc.raw, and there are ID numbers that I 
> would like to read them in character format. However, the way 
> the ID numbers are created makes it hard to do so. For 
> example, I have an ID is "00020", but Stata read it as "20". 
> Can anyone help me out here? I use "infix id 1-5 using ..." 
> but it does not work.
> 

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