Displaying 1 result from an estimated 1 matches for "tgtnjmoi".
2011 Jul 22
2
averaging rows based on string¿?
Hi Folks,
Ran into something I'd really like to do in R simply/elegantly, but my R -
coding skills seem surpassed. This is the thing. Imagine the following data:
labs<-c("abcdef","abcgg","tgthefdk","tgtijuel","tgtnjmoi","gbnt","dlift")
dat<-c(0.5,0.25,1,2,16,0.250,4)
dframe<-data.frame(labs,dat)
I would like to average the values in "dat" according to specific
string/text in the name of their row names described by "labs". For example,
average the values in &quo...