EZvFigPrint.m 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147
  1. % EZvFigPrint.m Called by [P} button to produce S curves for publication
  2. global ghandles
  3. global Exp
  4. try
  5. lnwidth=str2num(Exp(4).plotPars{1})
  6. axisFontSz=str2num(Exp(4).plotPars{2})
  7. legFontSz=str2num(Exp(4).plotPars{3})
  8. markerSz=str2num(Exp(4).plotPars{4})
  9. catch
  10. lnwidth=4;
  11. axisFontSz=36;
  12. legFontSz=10;
  13. markerSz=5;
  14. end
  15. if get(ghandles.printOL1,'Value')==1,zone=1; end
  16. if get(ghandles.printOL2,'Value')==1,zone=2; end
  17. if get(ghandles.printOL3,'Value')==1,zone=3; end
  18. semiLog=0;
  19. if isequal(get(ghandles.OLaxes1,'YScale'),'log'), semiLog=1;end
  20. if isequal(get(ghandles.OLaxes2,'YScale'),'log'), semiLog=1;end
  21. if isequal(get(ghandles.OLaxes3,'YScale'),'log'), semiLog=1;end
  22. clear legName tmp
  23. figure
  24. set(gcf,'OuterPosition',(get(0,'screensize')))
  25. hn=0;
  26. if isequal(get(Exp(zone).hOL(1),'Visible'),'on')
  27. disphOLX(1)={get(Exp(zone).hOL(1),'XData')}
  28. disphOLY(1)={get(Exp(zone).hOL(1),'YData')}
  29. tmp(1)=strrep(Exp(zone).hOLname(1),'_','-')
  30. try
  31. disphOLbX(1)={get(Exp(zone).hOLb(1),'XData')}
  32. disphOLbY(1)={get(Exp(zone).hOLb(1),'YData')}
  33. catch end
  34. hn=hn+1
  35. notDup=1;
  36. end
  37. notDup=0;
  38. for hN=2:length(Exp(zone).hOL)
  39. % Bounce-dupicate data removal
  40. for j=1:(hN-1)
  41. if isequal(Exp(zone).hOLname(hN), Exp(zone).hOLname(j))%&& ...
  42. % isequal(get(Exp(zone).hOL(hN),'Visible'),'on')
  43. notDup=0;
  44. break
  45. else
  46. notDup=1;
  47. end
  48. end
  49. if notDup==1
  50. if isequal(get(Exp(zone).hOL(hN),'Visible'),'on')
  51. hn=hn+1
  52. try
  53. disphOLX(hn)={get(Exp(zone).hOL(hN),'XData')};
  54. disphOLY(hn)={get(Exp(zone).hOL(hN),'YData')};
  55. tmp(hn)=strrep(Exp(zone).hOLname(hN),'_','-')
  56. try
  57. disphOLbX(hn)={get(Exp(zone).hOLb(hN),'XData')};
  58. disphOLbY(hn)={get(Exp(zone).hOLb(hN),'YData')};
  59. catch
  60. end
  61. tmp(hn)=strrep(Exp(zone).hOLname(hN),'_','-')
  62. catch ME
  63. disp(ME)
  64. display('error leading to line 59 catch')
  65. end
  66. end
  67. end
  68. end
  69. for i=1:hn
  70. if semiLog==0
  71. hprint=plot(cell2mat(disphOLX(i)),cell2mat(disphOLY(i)))
  72. set(hprint,'linewidth',lnwidth) %0.5 then 1.5 now 6
  73. set(gca,'fontsize',axisFontSz) % 8 to 15 to 21
  74. linecolor(i)={get(hprint,'color')};
  75. else
  76. hprint=semilogy(cell2mat(disphOLX(i)),cell2mat(disphOLY(i)))
  77. set(hprint,'linewidth',lnwidth) %0.5 then 1.5 now 4.0
  78. set(gca,'fontsize',axisFontSz) % 8 to 15 to 21
  79. linecolor(i)={get(hprint,'color')};
  80. end
  81. hold all
  82. end
  83. if Exp(zone).CompositPlot~=1 % Standard plot, Not a Composite Plot
  84. legName=tmp
  85. hleg=legend((legName),'location','NEO')
  86. set(hleg,'fontsize',legFontSz)
  87. try
  88. for i=1:hn
  89. if semiLog==0
  90. hprint=plot(cell2mat(disphOLbX(i)),cell2mat(disphOLbY(i)),'marker','+','markerEdgeColor',cell2mat(linecolor(i)),'markerSize',markerSz, 'linestyle','none')
  91. else
  92. hprint=semilogy(cell2mat(disphOLbX(i)),cell2mat(disphOLbY(i)),'marker','+','markerEdgeColor',cell2mat(linecolor(i)),'markerSize',markerSz, 'linestyle','none')
  93. end
  94. end
  95. catch
  96. end
  97. hold off
  98. % End of Standard Overlay Plot
  99. else % if Composite Plot
  100. for hcN=1:(Exp(zone).cTraceN -1)
  101. disphOLX(hcN)={get(Exp(zone).hCmean(hcN),'XData')};
  102. disphOLY(hcN)={get(Exp(zone).hCmean(hcN),'YData')};
  103. disphOLbX(hcN)={get(Exp(zone).hBound1(hcN),'XData')};
  104. disphOLbY(hcN)={get(Exp(zone).hBound1(hcN),'YData')};
  105. disphOLcX(hcN)={get(Exp(zone).hBound2(hcN),'XData')};
  106. disphOLcY(hcN)={get(Exp(zone).hBound2(hcN),'YData')};
  107. tmp(hcN)=(Exp(zone).cName(hcN))
  108. if semiLog==0
  109. hprint=plot(cell2mat(disphOLX(hcN)),cell2mat(disphOLY(hcN)))
  110. set(hprint,'linewidth',lnwidth) %0.5 then 1.5 now 6
  111. set(gca,'fontsize',axisFontSz) % 8 to 15 to 21
  112. linecolor(hcN)={get(hprint,'color')};
  113. else
  114. hprint=semilogy(cell2mat(disphOLX(hcN)),cell2mat(disphOLY(hcN)))
  115. set(hprint,'linewidth',lnwidth) %0.5 then 1.5 now 4.0
  116. set(gca,'fontsize',axisFontSz) % 8 to 15 to 21
  117. linecolor(hcN)={get(hprint,'color')};
  118. end
  119. hold all
  120. legName=tmp
  121. hleg=legend((legName),'location','NEO')
  122. set(hleg,'fontsize',legFontSz)
  123. %{
  124. for i=1:hn
  125. hprint=plot(cell2mat(disphOLbX(i)),cell2mat(disphOLbY(i)),'marker','+','markerEdgeColor',cell2mat(linecolor(i)),'markerSize',markerSz, 'linestyle','none')
  126. end
  127. %}
  128. end
  129. for i=1:(Exp(zone).cTraceN -1)
  130. hBprint=plot(cell2mat(disphOLbX(i)),cell2mat(disphOLbY(i)))
  131. set(hBprint,'linewidth',.5) %lnwidth) %0.5 then 1.5 now 6
  132. set(hBprint,'color',linecolor{i})
  133. hCprint=plot(cell2mat(disphOLcX(i)),cell2mat(disphOLcY(i)))
  134. set(hCprint,'linewidth',0.5) %lnwidth) %0.5 then 1.5 now 6
  135. set(hBprint,'color',linecolor{i})
  136. end
  137. hold off
  138. end