Re: [R] Help on indicator variables

2013-03-22 Thread Tasnuva Tabassum
SE->0, TRUE->1) when used in > > arithmetic so you can do, e.g., mean(bL) to see what proportion of > > your cases satisfy the condition. > > > > Bill Dunlap > > Spotfire, TIBCO Software > > wdunlap tibco.com > > > > > >> -Or

Re: [R] Help on indicator variables

2013-03-22 Thread peter dalgaard
t;> From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On >> Behalf >> Of Tasnuva Tabassum >> Sent: Thursday, March 21, 2013 6:03 AM >> To: R help >> Subject: [R] Help on indicator variables >> >> I have two indicator variables ABS and DE

Re: [R] Help on indicator variables

2013-03-21 Thread William Dunlap
lap Spotfire, TIBCO Software wdunlap tibco.com > -Original Message- > From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On > Behalf > Of Tasnuva Tabassum > Sent: Thursday, March 21, 2013 6:03 AM > To: R help > Subject: [R] Help on indicator va

Re: [R] Help on indicator variables

2013-03-21 Thread Göran Broström
On 03/21/2013 02:08 PM, Jorge I Velez wrote: Try ifelse(ABS ==1 | DEFF == 1, 1, 0) or as.numeric(ABS | DEFF) (faster?) Göran HTH, Jorge.- On Fri, Mar 22, 2013 at 12:02 AM, Tasnuva Tabassum wrote: I have two indicator variables ABS and DEFF. I want to create another indicator variabl

Re: [R] Help on indicator variables

2013-03-21 Thread Jorge I Velez
Try ifelse(ABS ==1 | DEFF == 1, 1, 0) HTH, Jorge.- On Fri, Mar 22, 2013 at 12:02 AM, Tasnuva Tabassum wrote: > I have two indicator variables ABS and DEFF. I want to create another > indicator variable which will take value 1 if either ABS=1 or DEFF=1. > Otherwise, it will take value 0. How c

[R] Help on indicator variables

2013-03-21 Thread Tasnuva Tabassum
I have two indicator variables ABS and DEFF. I want to create another indicator variable which will take value 1 if either ABS=1 or DEFF=1. Otherwise, it will take value 0. How can I make that? [[alternative HTML version deleted]] __ R-help@r-pr