comparison Problems/private/sprow.m @ 15:51b76c31c93d

(none)
author idamnjanovic
date Thu, 25 Mar 2010 14:05:27 +0000
parents
children
comparison
equal deleted inserted replaced
14:a0571bf2ff54 15:51b76c31c93d
1 %SPROW Extract row of sparse matrix.
2 % X = SPROW(A,J) where A is a sparse matrix, returns the nonzero values in
3 % the row A(J,:).
4 %
5 % [X,ID] = SPROW(A,J) also returns the column indices of the nonzeros.
6 %
7 % Note that the call [X,ID] = SPROW(A,J) is equivalent (but more efficient
8 % than) the Matlab code
9 %
10 % IDS = find(A(J,:));
11 % X = A(J,IDS);
12
13
14 % Ron Rubinstein
15 % Computer Science Department
16 % Technion, Haifa 32000 Israel
17 % ronrubin@cs
18 %
19 % August 2009