Hi, the global row indexing for my cluster assignment is as : buf <- tapply(test1, test2, FUN = function(x){x;}) $`1` [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 $`2` [1] 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80
I used "tapply" function to find minimum as: > foo <- tapply(dist, test2, FUN = which.min) which prints: 1 2 16 17 I want it to print the miminum based on global row indexing as: 1 2 16 77 How can I get to print the actual entry instead of re-counted entry? Any help? Thanks. -- View this message in context: http://r.789695.n4.nabble.com/how-to-print-global-index-from-tapply-function-tp4632855.html Sent from the R help mailing list archive at Nabble.com. ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.