Histograms from point cloud
显示 更早的评论
Hello,
Basically, I have 3D coordinates points (xyzPoints) and I want to display 3 histograms of x, y and z coordinates values in order to visualize the density of data cloud.
xyzPoints = reconstructScene(disparityMap, stereoParamsTEST);
xyzPoints = xyzPoints./1000;
ptCloud = pointCloud(xyzPoints);
figure(4);
pcshow(ptCloud);
title('Point cloud');
How do I create variables for x, y and z coordinates values to do this :
subplot(2,2,1);
hist(x);
subplot(2,2,2);
hist(y);
subplot(2,2,3);
hist(z);
Thanks
采纳的回答
更多回答(1 个)
Steven Lord
2019-7-9
1 个投票
You said in your comment to Rik's answer that xyzPoints is size [2019 4063 3]. I assume therefore that the x data is the first page of that data xyzPoints(:, :, 1), the y data is the second page xyzPoints(:, :, 2), and the z data is the third page xyzPoints(:, :, 3)? If so, call histogram on each of those pages of data.
Alternately you could plot them using scatter3 or perhaps make a trio of heatmap plots: one for x versus y, one for x versus z, and one for y versus z.
类别
在 帮助中心 和 File Exchange 中查找有关 Histograms 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!