On Jan 30, 2012, at 9:52 AM, kerry1912 wrote:
I want to perform two if functions at the same time: if(home team > away team & home team <= away team + 7) in R but i am struggling to work out how to write this correctly.
Generally newcomers to the R language find that the "ifelse" function does what they expect. The "if" function is quite different and seemes less likely to be what you wnat:
?Control ?ifelse -- David Winsemius, MD Heritage Laboratories West Hartford, CT ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.