Skip to content
Prev 199127 / 398506 Next

creating mulptiple new variables from one data.frame according to columns and rows in that frame

YES, that does the trick.
Glad to have your help for I had no idea of the existence of FAQ 7.31 nor for that matter do I completely understand what floating point number are (but that is another story :P))
Think I am all set.
Cheers again for your time and energy.

Daniel

-----Original Message-----
From: jim holtman [mailto:jholtman at gmail.com] 
Sent: 04 November 2009 15:30
To: Hayes, Daniel
Cc: r-help at lists.R-project.org
Subject: Re: [R] creating mulptiple new variables from one data.frame according to columns and rows in that frame

My guess is that we are being affected by FAQ 7.31 (good old floating
point numbers).  The test 'age %in% 5:50' might be affected by round
off.  Something like the following might be better:

age < 5 | (abs(age - round(age)) < 0.001)

This should give TRUE for all ages that are 'close' to the year.  Take
a look at your data where you thing values might be missing and set
'options(digit=20)' to print out the full values.
On Wed, Nov 4, 2009 at 8:03 AM, Hayes, Daniel <D.J.Hayes at liverpool.ac.uk> wrote: