Hello Izabela,
You may use the following:
--> x = [1.1 1.1 3.2; 2.3 1.1 1.1; 4.7 5.2 5.2]
x =
1.1 1.1 3.2
2.3 1.1 1.1
4.7 5.2 5.2
--> r = tabul(x); r(r(:,2)==1,1)
ans =
4.7
3.2
2.3
Samuel
___
users mailing list
use
Hello,
Maybe not optimal, but does the job:
x = [1 1 3
2 1 1
4 5 5];
f = [];
for y=unique(x(:))'
if length(find(x==y)) == 1
f = [f y];
end
end
--> f
f =
2. 3. 4.
S.
Le 05/07/2019 à 18:03, Izabela Wójcik-Grząba a écrit :
Hello,
Is there a simple way of finding elements of m
Hello,
Is there a simple way of finding elements of matrix which occurs only
once. For example in this matrix it would be 3 and 4:
[1 1 3
2 1 1
4 5 5]
For the time being I couldn't find any smart idea for that. Could you
help?
Kind regards,
Iza
__