dat1$VARNEW<-rep("unknown",nrow(dat1))
dat1$VARNEW[dat1$RES_STA=="X" & dat1$BIRTHPLACE %in%
c("AG","AI","AR","BE","ZH")]<-"swiss"
--- On Wed, 30/1/13, arun wrote:
From: arun
Subject: Re: [R] recoding va
$RES_STA=="X" &
dat1$BIRTHPLACE%in%c("AG","AI","AR","BE","ZH"),"swiss","unknown")
A.K.
- Original Message -
From: David Studer
To: r-help@r-project.org
Cc:
Sent: Wednesday, January 30, 2013 4:42 AM
Subject:
Hi David,
Check
?"%in%"
for a simpler approach.
Regards,
Jorge.-
On Wed, Jan 30, 2013 at 8:42 PM, David Studer <> wrote:
> Hello everybody!
>
> I have again a rather simple question concerning recoding of variables:
>
> I have a variable/data-frame column BIRTHPLACE containing abbreviations
Hello everybody!
I have again a rather simple question concerning recoding of variables:
I have a variable/data-frame column BIRTHPLACE containing abbreviations of
the 26 swiss counties (AG, AI, AR, BE, ZH, ... )
as well as international country codes (USA, GER, ESP, etc.) and another
variable RE
4 matches
Mail list logo