In the file of interest, the observation units are U.S. census tracts, with latitude and longitude among the variables that matter to me. I noticed that:
1) Stata imported latitude/longitude as floats, not doubles, which could matter in some applications.
2) -import dbf- does not have any type options
3) MS Excel gets different values for these variables than does Stata, with absolute differences around 1e-6
I'm guessing (?) that Excel imported the dbf file at double precision?
For example:
Code:
Lat (Excel) | Lat(Stata) | abs diff | ||
32.4770395818 | 32.4770393372 | 2.4464E-07 | ||
32.4742513120 | 32.4742507935 | 5.1854E-07 | ||
32.4754284379 | 32.4754295349 | 1.09701E-06 | ||
32.4719824405 | 32.4719810486 | 1.39192E-06 | ||
32.4586597838 | 32.4586601257 | 3.4193E-07 |
All I can think of here is -odbc- (I don't see anything about a double option in -odbc-.) I'd hate to have to import multiple dbfs into Excel and then -import excel-.
0 Response to Data type/precision -import dbf-
Post a Comment