rankboostaucold.m
来自「各种SVM分类算法」· M 代码 · 共 39 行
M
39 行
function [alpha,threshold,rankfeat]=rankboostAUC(xapp,yapp,T);
% USAGE
%
% [alpha,threshold,rankfeat]=rankboostAUC(xapp,yapp,T);
%
% This a Rankboost algorithm as described in the freund et al
% Journal of Machine Learning Research paper.
%
% xapp and yapp are the learning set data and labels
% T is the number of weak learners which is a step function.
%
% the outputs are
%
% alpha : vector of weigth of each weak learner
% threshold : vector of each weak learner translation
% rankfeat : vector of each weak learner feature.
%
% see also rankboostAUCval
% 30/07/2004 A. Rakotomamonjy
%
%
[n,dim]=size(xapp);
indpos=find(yapp==1);
npos=length(indpos);
indneg=find(yapp==-1);
nneg=length(indneg);
yapp=[yapp(indpos);yapp(indneg)]; % on remet les donn閑s en ordre!
xapp=[xapp(indpos,:);xapp(indneg,:)];
indpos=find(yapp==1);
indneg=find(yapp==-1);
% dans les vecteurs on stocke d'abord les v(xo) puis les v(x1) xo c'est les
% pos et x1 les neg par rapport
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?