Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: unique() Help
Date: Mon, 7 Sep 2009 15:58:02 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 9
Message-ID: <h83aia$5dv$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-02-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1252339082 5567 172.30.248.37 (7 Sep 2009 15:58:02 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Mon, 7 Sep 2009 15:58:02 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1477385
Xref: news.mathworks.com comp.soft-sys.matlab:568784


Hello,
I need a function that outputs the unique elements of each column of my desired matrix.
I can use 
sum(~~diff(sort(A)))+1
to get the number of unique elements in each column of a matrix A,
but can't I produce a cell or zero padded matrix for what the unique elements are?
I used a loop and it takes 99% of my calculation time and is killing me!

Help!!!