mreCenter1 = []; mreCenter2 = []; mreCenter5 = []; for i = 1:20 myTempGac = mreGac2(i,:); tempTestInstanceType = testInstanceType(i,:); mreCenter1 = [mreCenter1;myTemp(find(tempTestInstanceType == 1))]; mreCenter2 = [mreCenter2;myTemp(find(tempTestInstanceType == 2))]; mreCenter5 = [mreCenter5;myTemp(find(tempTestInstanceType == 5))]; end mre21 = mreCenter1; mre22 = mreCenter1; mre23 = mre7; mre24 = mre16; win = zeros(10,1); tie = zeros(10,1); loss = zeros(10,1); % start calculating win tie loss values for i = 1:10 for j = 1:10 if i ~= j % if i and j are different for k = 1:size(mre1,1) eval(['[P,H] = RANKSUM(mre2',num2str(i),'(',num2str(k),',:),mre2',num2str(j),'(',num2str(k),',:));']); if H == 0 % if they are the same eval(['tie(',num2str(i),') = tie(',num2str(i),') +1;']); eval(['tie(',num2str(j),') = tie(',num2str(j),') +1;']); else % calculate median values eval(['medi = median(mre2',num2str(i),'(',num2str(k),',:));']); eval(['medj = median(mre2',num2str(j),'(',num2str(k),',:));']); if medi < medj eval(['win(',num2str(i),') = win(',num2str(i),') +1;']); eval(['loss(',num2str(j),') = loss(',num2str(j),') +1;']); else eval(['win(',num2str(j),') = win(',num2str(j),') +1;']); eval(['loss(',num2str(i),') = loss(',num2str(i),') +1;']); end end end end end end win = win./2 tie= tie./2 loss = loss./2