Hello

I have the following variables, all of which are logicals

fmar15   fcoc15   fher15    fcrk15    fidu15

what I would like is a variable drug15 which equals 
idu if fidu15 is T; crk if fidu15 is F but fcrk is T, her if fher15 is
T but fcrk15 and fidu15 are F and so on

What's the best way to do this?  

Thanks in advance

Peter L. Flom, PhD
Assistant Director, Statistics and Data Analysis Core
Center for Drug Use and HIV Research
National Development and Research Institutes
71 W. 23rd St
www.peterflom.com
New York, NY 10010
(212) 845-4485 (voice)
(917) 438-0894 (fax)

______________________________________________
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help

Reply via email to