[R] checking for identical columns in a mxn matrix

2003-12-03 Thread Rajarshi Guha
Hi, I have a rectangular matrix and I need to check whether any columns are identical or not. Currently I'm looping over the columns and checking each column with all the others with identical(). However, as experience has shown me, getting rid of loops is a good idea :) Would anybody have any

Re: [R] checking for identical columns in a mxn matrix

2003-12-03 Thread Marc Schwartz
On Wed, 2003-12-03 at 12:06, Rajarshi Guha wrote: Hi, I have a rectangular matrix and I need to check whether any columns are identical or not. Currently I'm looping over the columns and checking each column with all the others with identical(). However, as experience has shown me,

RE: [R] checking for identical columns in a mxn matrix

2003-12-03 Thread Liaw, Andy
From: Rajarshi Guha On Wed, 2003-12-03 at 13:18, J.R. Lockwood wrote: list will come up with something clever. the other issues is that you need to be careful when doing equality comparisons with floating point numbers. unless your matrix consists of characters or integers,