[R] a bug when subtracting vectors?

2007-09-24 Thread Samuel Kemp
Hi, I am calling in some data into R via the read.table function. The 'tail' of this data reads tail(data) Date Open HighLow Close Volume 3728 Fri 14-Sep-07 114.19 114.46 113.93 114.08 1117992 3729 Mon 17-Sep-07 113.99 114.37 113.91 114.27 899671 3730

Re: [R] a bug when subtracting vectors?

2007-09-24 Thread Raymond Wan
Samuel Kemp wrote: When subtracting, all numbers should be to 2 decimal places. Why is R calculating it to 15 decimal places -- the output is essentially wrong 112.47-112.30=0.17 NOT 0.172. I suspect I am encoding this incorrectly? Well, two comments...one is not computer