Hi Letter,

This should do it:
testchange <- ifelse(testseq <= 4,'x', ifelse(testseq >= 5, 'y', testseq))

Read it as: if testseq <=4, print x, ifelse test seq >=5, print y, any
other case, print testseq.

        [[alternative HTML version deleted]]

R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to