Files
hartman-server/qhtcp-workflow/apps/matlab/ezview/EZvFigPrint.m

148 lines
4.8 KiB
Matlab
Executable File

% EZvFigPrint.m Called by [P} button to produce S curves for publication
global ghandles
global Exp
try
lnwidth=str2num(Exp(4).plotPars{1})
axisFontSz=str2num(Exp(4).plotPars{2})
legFontSz=str2num(Exp(4).plotPars{3})
markerSz=str2num(Exp(4).plotPars{4})
catch
lnwidth=4;
axisFontSz=36;
legFontSz=10;
markerSz=5;
end
if get(ghandles.printOL1,'Value')==1,zone=1; end
if get(ghandles.printOL2,'Value')==1,zone=2; end
if get(ghandles.printOL3,'Value')==1,zone=3; end
semiLog=0;
if isequal(get(ghandles.OLaxes1,'YScale'),'log'), semiLog=1;end
if isequal(get(ghandles.OLaxes2,'YScale'),'log'), semiLog=1;end
if isequal(get(ghandles.OLaxes3,'YScale'),'log'), semiLog=1;end
clear legName tmp
figure
set(gcf,'OuterPosition',(get(0,'screensize')))
hn=0;
if isequal(get(Exp(zone).hOL(1),'Visible'),'on')
disphOLX(1)={get(Exp(zone).hOL(1),'XData')}
disphOLY(1)={get(Exp(zone).hOL(1),'YData')}
tmp(1)=strrep(Exp(zone).hOLname(1),'_','-')
try
disphOLbX(1)={get(Exp(zone).hOLb(1),'XData')}
disphOLbY(1)={get(Exp(zone).hOLb(1),'YData')}
catch end
hn=hn+1
notDup=1;
end
notDup=0;
for hN=2:length(Exp(zone).hOL)
% Bounce-dupicate data removal
for j=1:(hN-1)
if isequal(Exp(zone).hOLname(hN), Exp(zone).hOLname(j))%&& ...
% isequal(get(Exp(zone).hOL(hN),'Visible'),'on')
notDup=0;
break
else
notDup=1;
end
end
if notDup==1
if isequal(get(Exp(zone).hOL(hN),'Visible'),'on')
hn=hn+1
try
disphOLX(hn)={get(Exp(zone).hOL(hN),'XData')};
disphOLY(hn)={get(Exp(zone).hOL(hN),'YData')};
tmp(hn)=strrep(Exp(zone).hOLname(hN),'_','-')
try
disphOLbX(hn)={get(Exp(zone).hOLb(hN),'XData')};
disphOLbY(hn)={get(Exp(zone).hOLb(hN),'YData')};
catch
end
tmp(hn)=strrep(Exp(zone).hOLname(hN),'_','-')
catch ME
disp(ME)
display('error leading to line 59 catch')
end
end
end
end
for i=1:hn
if semiLog==0
hprint=plot(cell2mat(disphOLX(i)),cell2mat(disphOLY(i)))
set(hprint,'linewidth',lnwidth) %0.5 then 1.5 now 6
set(gca,'fontsize',axisFontSz) % 8 to 15 to 21
linecolor(i)={get(hprint,'color')};
else
hprint=semilogy(cell2mat(disphOLX(i)),cell2mat(disphOLY(i)))
set(hprint,'linewidth',lnwidth) %0.5 then 1.5 now 4.0
set(gca,'fontsize',axisFontSz) % 8 to 15 to 21
linecolor(i)={get(hprint,'color')};
end
hold all
end
if Exp(zone).CompositPlot~=1 % Standard plot, Not a Composite Plot
legName=tmp
hleg=legend((legName),'location','NEO')
set(hleg,'fontsize',legFontSz)
try
for i=1:hn
if semiLog==0
hprint=plot(cell2mat(disphOLbX(i)),cell2mat(disphOLbY(i)),'marker','+','markerEdgeColor',cell2mat(linecolor(i)),'markerSize',markerSz, 'linestyle','none')
else
hprint=semilogy(cell2mat(disphOLbX(i)),cell2mat(disphOLbY(i)),'marker','+','markerEdgeColor',cell2mat(linecolor(i)),'markerSize',markerSz, 'linestyle','none')
end
end
catch
end
hold off
% End of Standard Overlay Plot
else % if Composite Plot
for hcN=1:(Exp(zone).cTraceN -1)
disphOLX(hcN)={get(Exp(zone).hCmean(hcN),'XData')};
disphOLY(hcN)={get(Exp(zone).hCmean(hcN),'YData')};
disphOLbX(hcN)={get(Exp(zone).hBound1(hcN),'XData')};
disphOLbY(hcN)={get(Exp(zone).hBound1(hcN),'YData')};
disphOLcX(hcN)={get(Exp(zone).hBound2(hcN),'XData')};
disphOLcY(hcN)={get(Exp(zone).hBound2(hcN),'YData')};
tmp(hcN)=(Exp(zone).cName(hcN))
if semiLog==0
hprint=plot(cell2mat(disphOLX(hcN)),cell2mat(disphOLY(hcN)))
set(hprint,'linewidth',lnwidth) %0.5 then 1.5 now 6
set(gca,'fontsize',axisFontSz) % 8 to 15 to 21
linecolor(hcN)={get(hprint,'color')};
else
hprint=semilogy(cell2mat(disphOLX(hcN)),cell2mat(disphOLY(hcN)))
set(hprint,'linewidth',lnwidth) %0.5 then 1.5 now 4.0
set(gca,'fontsize',axisFontSz) % 8 to 15 to 21
linecolor(hcN)={get(hprint,'color')};
end
hold all
legName=tmp
hleg=legend((legName),'location','NEO')
set(hleg,'fontsize',legFontSz)
%{
for i=1:hn
hprint=plot(cell2mat(disphOLbX(i)),cell2mat(disphOLbY(i)),'marker','+','markerEdgeColor',cell2mat(linecolor(i)),'markerSize',markerSz, 'linestyle','none')
end
%}
end
for i=1:(Exp(zone).cTraceN -1)
hBprint=plot(cell2mat(disphOLbX(i)),cell2mat(disphOLbY(i)))
set(hBprint,'linewidth',.5) %lnwidth) %0.5 then 1.5 now 6
set(hBprint,'color',linecolor{i})
hCprint=plot(cell2mat(disphOLcX(i)),cell2mat(disphOLcY(i)))
set(hCprint,'linewidth',0.5) %lnwidth) %0.5 then 1.5 now 6
set(hBprint,'color',linecolor{i})
end
hold off
end