delete Xn,Yn and Zn points from point cloud that are equal to Xn, Yn and Zn point from another cloud

3 Ansichten (letzte 30 Tage)
Hi all,
I got X,Y and Z point cloud, (4500x3 matrix) after plotting this figure I used the brushing tool to select some point of the data wich i saved in a new varriable. (600x3 matrix --> also x, y and z coördinates)
Now I want to delete the selected data from the original point cloud (4500x3 matrix) - (600x3 matrix) --> (3900x 3 matrix) so that al the data were for the (X & Y & Z) from the Original pointcloud = (x & y & z) of the selected point cloud are deleted.
Thanks in advance!

Akzeptierte Antwort

Baltam
Baltam am 15 Apr. 2016
Bearbeitet: Baltam am 18 Apr. 2016
Suppose your variables are called
OriginalPointCloud % (4500x3)
BrushData % (600x3)
NewPointCloud = OriginalPointCloud;
NewPointCloud(ismember(OriginalPointCloud,BrushData,'rows')) = NaN;
Kind regards, Baltam
  4 Kommentare
Allan Uytterhoeven
Allan Uytterhoeven am 18 Apr. 2016
Just found the perfect solution!! >> A= [1 1 1; 2 2 2; 1 2 3; 2 5 6; 8 4 5]
A =
1 1 1
2 2 2
1 2 3
2 5 6
8 4 5
>> B= [ 1 1 1; 8 4 5]
B =
1 1 1
8 4 5
>> C=setdiff(A,B,'rows')
C =
1 2 3
2 2 2
2 5 6

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by