Code was working fine, Same code is giving error 'Undefined function or variable 'pixelList'.
6 次查看(过去 30 天)
显示 更早的评论
On the attached code I am trying to identify the number of pixel values below and above the threshold which is median value of the pixelvalues in this case. The code was working fine. But now it is giving me error "Undefined function or variable 'pixelList'." Can anyone help me why I am having this error. Also I put the values in struct and tried to write it in excel file. But it is only writing one images information in the file , I have 67 image files in the folder.
0 个评论
采纳的回答
Walter Roberson
2018-11-9
Change
s(k).numberOfPixels = numel(pixelList);
To
s(k).numberOfPixels = numel(s(k).pixelList);
2 个评论
Walter Roberson
2018-11-9
Your writetable is inside the loop and you are not providing a range, so you would overwrite the file each time.
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Spreadsheets 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!