Also tried this but results werent any different
subset1<- subset(dframe, glb_ind="Y" | sample==1 | !is.na(glb_ind))
subset2<-subset(dframe, cwar_ind="Y" |sample==2 | !is.na(cwar_ind))
subset3<-subset(dframe, reg_ind="Y" | sample==3 | !is.na(reg_ind))
The problem might be that "NAs" in the dataset are blank
On Wed, Jun 5, 2013 at 9:54 AM, Daniel Tucker wrote:
> Also tried this but results werent any different
>
> subset1<- subset(dframe, glb_ind="Y" | sample==1 | !is.na(glb_ind))
> subset2<-subset(df
I am trying to create a new datafarme using the subset function given 2
conditions
subset1<- subset(dframe, glb_ind="Y" | sample==1)
subset2<-subset(dframe, cwar_ind="Y" | sample==2)
subset3<-subset(dframe, reg_ind="Y" | sample==3)
However, my first conditions (glb_ind,cwar_ind, and reg_ind) all
; On Wed, May 29, 2013 at 10:37 AM, Daniel Tucker
> wrote:
>
>> R list members,
>>
>> I am trying to replicate a command script in STATA and find
>> equivalency in R to the following Stata command:
>>
>> egen stratida = concat(year byregn2 group) if sample==1
R list members,
I am trying to replicate a command script in STATA and find
equivalency in R to the following Stata command:
egen stratida = concat(year byregn2 group) if sample==1
egen stratidb = concat(year byregn2 group) if sample==2
egen stratidc = concat(year byregn2 group) if sample==3
Not
5 matches
Mail list logo