> So I was thinking of embedding it into a if else loop but I am stuck on how > to define the "belongs to" in R syntax. Any hint will be much appreciated.
?ifelse # handles vectors, while if() handles single values ?'%in%' # also see match() and which() Enjoy the day, cur -- Curt Seeliger, Data Ranger Raytheon Information Services - Contractor to ORD seeliger.c...@epa.gov 541/754-4638 [[alternative HTML version deleted]] ______________________________________________ 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.