R: mixedsort on multiple vectors (columns)
问题 This is a follow-up on this question, which was marked as a duplicate to this, but the suggested solution does not work. I have the following data.frame : set.seed(1) mydf <- data.frame(A=paste(sample(LETTERS, 4), sample(1:20, 20), sep=""), B=paste(sample(1:20, 20), sample(LETTERS, 4), sep=""), C=sample(LETTERS, 20), D=sample(1:100, 20), value=rnorm(20)) > mydf A B C D value 1 G5 6N T 9 -0.68875569 2 J18 8T R 87 -0.70749516 3 N19 1A L 34 0.36458196 4 U12 7K Z 82 0.76853292 5 G11 14N J 98 -0