Something like: keep <- apply(myData, 2, function(x) diff(range(x)) > 0) newData <- myData[, keep]
Andy > From: Moises Hassan > > I'm looking for an efficient way of removing zero-variance > columns from > a large matrix. > > Any suggestions? > > Thanks, > > - Moises > ______________________________________________ [EMAIL PROTECTED] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
