Displaying 1 result from an estimated 1 matches for "lesion2".
Did you mean:
lesions
2010 Mar 14
2
code rows depending on the value of other rows in multilevel dataframe
...Slice),
which( Lesion == 2) )
df [ for that particular (ID, Date,Segment, and slice) ,
which(Tract == Whole) ] $Lesion <- 2
else
df [ for that particular (ID, Date,Segment, and slice) ,
which(Tract == Whole) ] $Lesion <- 0
I started with (don't know if this is the right path),
Lesion2<-df[which(df$Lesion == 2),]
Where.Lesion2<-unique(Lesion2[,1:4])
Whole<-subset(df, Tract == "Whole")
But stuck at how to match the ID/Date/Segment/Slice from Where.Lesion2 to Whole.
Regards
Gordon