Skip to content
Permalink
master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
load VISAA
hh = newcolormap('heated');
Npatot = VIS.Npat + VIS.Ntest;
FV = VIS.FVs.FV;
Nbm = VIS.FVs.Nbm;
% AA 8/23/20 Poly sorted by class
reslabel = [1 2 3 13 14];
metlabel = [15 16 17 18 19 20 21];
senslabel = [4 5 6 7 8 9 10 11 12 22 23];
% % BB or DD 8/23/20 Straight Ag-Pol sorted by class
% reslabel = [1 2 3 4 22];
% metlabel = [5 6 7 8 9 10 11];
% senslabel = [12 23 13 14 15 16 17 18 19 20 21];
FVres = FV(reslabel,:);
FVmet = FV(metlabel,:);
FVsens = FV(senslabel,:);
[~,finalres] = hierarchcluster(vec2simtest(FVres,9));
[~,finalmet] = hierarchcluster(vec2simtest(FVmet,9));
[~,finalsens] = hierarchcluster(vec2simtest(FVsens,9));
newreslabel = reslabel(finalres);
newmetlabel = metlabel(finalmet);
newsenslabel = senslabel(finalsens);
newlabel = concat(concat(newreslabel,newmetlabel),newsenslabel);
FVsrt = FV(newlabel,:);
Sim = vec2simtest(FVsrt,9);
figure(100)
imagesc(Sim)
caxis([-1 1])
colormap(hh)
patmp = concat(concat(VIS.patnam.resist,VIS.patnam.sens),VIS.patnam.test);
patname = patmp(newlabel);
for loop = 1:Npatot
text(Npatot+0.6,loop,char(patname(loop)))
end
set(gcf,'Color','white')
figure(101)
imagesc(FVsrt)
colormap(hh)
caxis([-2 2])
for loop = 1:Npatot
text(Nbm+0.6,loop,char(patname(loop)))
end
bmname = VIS.FVs.BMName;
for loop = 1:Nbm
text(loop-0.4,0,char(bmname(loop)))
end
set(gcf,'Color','white')
pred = concat(VIS.Pred,VIS.Pretest);
prederr = concat(VIS.Predstd,VIS.Preteststd);
predict = pred(newlabel);
predicterr = prederr(newlabel);
x = 1:length(predict);
figure(102)
bar(x,predict)
hold on
er = errorbar(x,predict,predicterr,predicterr);
er.Color = [0 0 0];
er.LineStyle = 'none';
er.LineWidth = 2;
hold off
g = gca;
for loop = 1:Npatot
text(loop,g.YLim(2),char(patname(loop)),'Rotation',90)
end
fid = fopen('PatPredict.txt','w');
fprintf(fid,'%s \t %s \t %s\n','Patient','Predict','ste');
for ploop = 1:Npatot
fprintf(fid,'%s \t %6.2f \t %6.2f\n',char(patname(ploop)),predict(ploop),predicterr(ploop));
end
fclose(fid);