Error 'Undefined variable "hisFtrs" or class "hisFtrs".'
1 次查看(过去 30 天)
显示 更早的评论
histFtrs = cell(6,1);
start = 1;
for i = 1 : 6
histFtrs{i} = hist(idx(start:start+size(features{i},2)),nWords)';
%normalize
histFtrs{i} = histFtrs{i}./sum(hisFtrs{i});
end
I am getting error as
Undefined variable "hisFtrs" or class "hisFtrs".
Error in checker (line 30)
histFtrs{i} = histFtrs{i}./sum(hisFtrs{i});
If anyone can help
0 个评论
采纳的回答
Alex Mcaulley
2019-2-27
At least in those lines of code you haven't defined hisFtrs variable. Can it be histFtrs?? If this is not the answer please provide the full code
3 个评论
Alex Mcaulley
2019-2-28
As I said before, your error is a typo in the line
histFtrs{i} = histFtrs{i}./sum(hisFtrs{i});
It should be:
histFtrs{i} = histFtrs{i}./sum(histFtrs{i});
Are you having more errors after changing this line?
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Histograms 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!