How to count the number of voxels of another color
조회 수: 4 (최근 30일)
이전 댓글 표시
Hi,
I was wondering how to count the number of voxels of one color in a three dimensional space
Thank you!
댓글 수: 3
Rik
2019년 9월 12일
You can use my answer to achieve this. When you have a logical array you can use sum to count the number of voxels.
채택된 답변
Rik
2019년 9월 11일
Similar to how you would do that for 2D:
IM=randi(255,[512 512 400]);
count=sum(IM==200,'all');
%if your release doesn't have the 'all' option:
%count=sum(IM(:)==200);
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Image Processing Toolbox에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!