📄 individualaccuracy.m.svn-base
字号:
function acc = individualAccuracy(trueY, predictedY, ranking)
%Compute the accuracy of a set of predictions for binary labels
%In the multi label case, all labels must be correct for 1 example
if (nargin < 2)
fprintf('%s\n', help(sprintf('%s', mfilename)));
error('Incorrect number of inputs - see above usage instructions.');
end
[numExamples, numLabels] = size(trueY);
acc = sum(trueY == predictedY, 1)/(numExamples);
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -