Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
read_por: imports incorrect values #413
While writing my own spss file reader I came across a bug in haven or ReadStat. See the attached example. The example shows only a single value, there are several others in the file (checked with foreign, spss, pspp and my package as well).
Welp. It looks like ReadStat was using base-10 for the exponent part instead of base-30. Since the exponent was 2 for this particular value, that explains why the result was off by a factor of 9 (30^2/10^2). The tests weren't catching it because ReadStat is lazy and never emits an exponent, just a long mantissa. I'll get this fixed ASAP.