Skip to content

read.table with double precision

3 messages · Alaios, michael.weylandt at gmail.com (R. Michael Weylandt, Sarah Goslee

I'm having trouble replicating/understanding why that would happen since I do it all the time. The only thing that raises a hint of suspicion is using the blank space separator , but I'm pretty sure that's fine  What does str() give? Possibly factors?

If you are sure that's happening as described, can you send a sample .txt ( won't get scrubbed) and your exact import code?

Michael
On Nov 17, 2011, at 11:49 AM, Alaios <alaios at yahoo.com> wrote:

            
#
Hi,
On Thu, Nov 17, 2011 at 11:49 AM, Alaios <alaios at yahoo.com> wrote:
Using that exact file you included? If so, then I suspect you are
confusing display and storage, though even then my default session
doesn't show integers.

How do you know that it is returning only integers? What is
options()$digits set to?
V1        V2       V3
1  1 50.790643 6.063498
2  2 50.790738 6.063471
3  3 50.791081 6.063380
4  4 50.791189 6.063552
[1] "50.7906430000"
What is str(myfile) ?

Sarah