[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]
Re: st: RE: Specifying and implied decimal place with an infixstatement
I would add that there is a slight danger in this method in general. In
case some of the raw data have actual decimal points, you probably want
their values (as they appear with the decimal points) to prevail.
-infile- with a dictionary takes care of this. In your case, a %3.1f
infmt is appropriate.
FYI, when an infmt such as %3.1f is used, Stata textually inserts a decimal
point if it is not present; then it reads the resulting string as a
number. SAS, on the other hand, for the equivalent operation, reads the
number first, and then divides by the appropriate power of 10 (this has
some other consequences). But in either case, an actual decimal point in
the raw data takes precedence.
At 03:41 PM 5/21/2004 +0100, you wrote:
I am not aware that you can. I'd just divide by
10 inside Stata. Any downside to that?
> I'm reading in a text file using an infix statment. Some of
> my variables
> (the nce variables) occupy 3 columns but have an implied
> decimal between
> the 2nd and 3rd columns. How do I correctly specify this in my infix
Institute for Policy Studies
Johns Hopkins University
* For searches and help try: