590 lines
22 KiB
Matlab
Executable File
590 lines
22 KiB
Matlab
Executable File
%EZvDatatip
|
|
%Calls to EZdestComp.m EZmDayTrend.m
|
|
|
|
global ghandles
|
|
global Exp
|
|
|
|
RFcmpGFlg=0; %Test 180105 as it goes to EZmDayTrend.m
|
|
lstBoxCmpFlg=0;
|
|
%datacursormode(gcf)
|
|
%{
|
|
[output_txt]=datatipp(obj,event_obj);
|
|
clkPos=getCursorInfo(datacursormode(gcf));
|
|
cpos=clkPos.Position;
|
|
htargetAxes= clkPos.Target;
|
|
%}
|
|
%pause(1)
|
|
curKey=get(gcf,'currentkey')
|
|
htMapFg=0;
|
|
|
|
if ghandles.Iaxes1==get(htargetAxes,'Parent'),expN=1;
|
|
elseif ghandles.Iaxes2==get(htargetAxes,'Parent'),expN=2;
|
|
elseif ghandles.Iaxes3==get(htargetAxes,'Parent'),expN=3;
|
|
elseif ghandles.OLaxes1==get(htargetAxes,'Parent'),OLay=1; expN=1; %zone=1; datacursormode off;
|
|
elseif ghandles.OLaxes2==get(htargetAxes,'Parent'),OLay=2; expN=2; %zone=2; datacursormode off;
|
|
elseif ghandles.OLaxes3==get(htargetAxes,'Parent'),OLay=3; expN=3; %zone=3; datacursormode off;
|
|
elseif ghandles.HtMap1==get(htargetAxes,'Parent'),expN=1; htMapFg=1;
|
|
elseif ghandles.HtMap2==get(htargetAxes,'Parent'),expN=2; htMapFg=1;
|
|
elseif ghandles.HtMap3==get(htargetAxes,'Parent'),expN=3; htMapFg=1;
|
|
else
|
|
return
|
|
end
|
|
|
|
if expN==1,DexpN= (get(ghandles.DN1,'value')); end
|
|
if expN==2,DexpN= (get(ghandles.DN2,'value')); end
|
|
if expN==3,DexpN= (get(ghandles.DN3,'value')); end
|
|
|
|
% Exp(expN).DexpN=DexpN;
|
|
if strcmp(Exp(expN).DexpType,'single'), DexpN=1; end
|
|
if exist('OLay','var'), clear ExpN; end
|
|
|
|
if ~exist('OLay','var')
|
|
try
|
|
ImageSel=expN<4
|
|
destPerMP= Exp(expN).Dexp(DexpN).destPerMP; %length(gS.DM1.drug);
|
|
MPsel=Exp(expN).Dexp(DexpN).MPsel; %floor(get(handles.MPsldr1,'value'));
|
|
pertSel=Exp(expN).Dexp(DexpN).pertSel; %floor(get(handles.DMsldr1,'value'));
|
|
tPtSel=Exp(expN).Dexp(DexpN).tPtSel; %floor(get(handles.Tptsldr1,'value'));
|
|
plateNum= Exp(expN).Dexp(DexpN).plateNum; %(MPsel1-1)*destPerMP1 + pertSel1;
|
|
scan= Exp(expN).Dexp(DexpN).scan;
|
|
|
|
|
|
MP=Exp(expN).Dexp(DexpN).MP;
|
|
%x2ypos= [1400-cpos(2) cpos(1)] %for HorzRotatedImage
|
|
ptrPos=[cpos(1),cpos(2)]; %for VerticleImage
|
|
if htMapFg==0 %Comes from spot image Iaxes
|
|
try
|
|
for m=1:24
|
|
for n=1:16
|
|
coord=Exp(expN).Dexp(DexpN).FexpScanSpots{plateNum}{m,n,tPtSel}; %replace {1} with {plateNum}
|
|
|
|
if ptrPos(2)> coord(1) && ptrPos(2)< coord(3)
|
|
if ptrPos(1)> coord(2) && ptrPos(1)<coord(4)
|
|
picLoc1= [n,m];
|
|
%indx=(picLoc1(1)-1)*24+picLoc1(2)
|
|
%spotFrm= Exp(expN).Dexp(DexpN).FexpScanSpots{1}{m,n,tPtSel};
|
|
spotFrm= Exp(expN).Dexp(DexpN).FexpScanSpots{plateNum}{m,n,tPtSel}; %20160108
|
|
end
|
|
end
|
|
end %for n=1:16
|
|
end %for m=1:24
|
|
destcompMsg= 'GoodDataTip';
|
|
catch
|
|
destcompMsg= 'BadDataTip';
|
|
m
|
|
n
|
|
end
|
|
|
|
plateLoc= [(17-picLoc1(1)) picLoc1(2)];
|
|
indx=(plateLoc(1)-1)*24+plateLoc(2);
|
|
elseif htMapFg==1 %Comes from HeatMap image Haxes
|
|
plateLoc= ptrPos;
|
|
indx=(plateLoc(1)-1)*24+plateLoc(2);
|
|
end
|
|
Exp(expN).Dexp(DexpN).spotIndx=indx;
|
|
|
|
K=scan(1,plateNum).plate(1).CFout(indx,3); Ks= num2str(K);
|
|
r=scan(1,plateNum).plate(1).CFout(indx,4); rs= num2str(r);
|
|
l=scan(1,plateNum).plate(1).CFout(indx,5); Ls= num2str(l);
|
|
try Kstr=Ks(1:5); catch, Kstr = Ks(1:length(Ks)); end
|
|
try rstr=rs(1:5); catch, rstr = rs(1:length(rs)); end
|
|
try Lstr=Ls(1:5); catch, Lstr = Ls(1:length(Ls)); end
|
|
|
|
Kl=scan(1,plateNum).plate(1).CFout(indx,7);
|
|
Ku=scan(1,plateNum).plate(1).CFout(indx,8);
|
|
rl=scan(1,plateNum).plate(1).CFout(indx,9);
|
|
ru=scan(1,plateNum).plate(1).CFout(indx,10);
|
|
lfast=scan(1,plateNum).plate(1).CFout(indx,11);
|
|
lslow=scan(1,plateNum).plate(1).CFout(indx,12);
|
|
t=1:200;
|
|
clear g;
|
|
|
|
try
|
|
g = K ./ (1 + exp(-r.* (t - l )));
|
|
gSlow= Kl ./ (1 + exp(-rl.* (t - lslow )));
|
|
gFast= Ku ./ (1 + exp(-ru.* (t - lfast )));
|
|
if K==0||r==0||l==0, g(1:200)=1;gSlow(1:200)=1;gFast(1:200)=1;end
|
|
tser=(scan(1,plateNum).plate(1).t0Series(:));
|
|
rawData= scan(1,plateNum).plate(1).intens(indx,:)/scan(1,plateNum).plate(1).Ag(indx);
|
|
|
|
if expN==1, plotAxes=ghandles.Paxes1; OLaxes=ghandles.OLaxes1;
|
|
Exp(1).traceN=Exp(1).traceN+1;
|
|
traceN=Exp(1).traceN;
|
|
end
|
|
if expN==2, plotAxes=ghandles.Paxes2; OLaxes=ghandles.OLaxes2;
|
|
Exp(2).traceN=Exp(2).traceN+1;
|
|
traceN=Exp(2).traceN;
|
|
end
|
|
if expN==3, plotAxes=ghandles.Paxes3; OLaxes=ghandles.OLaxes3;
|
|
Exp(3).traceN=Exp(3).traceN+1;
|
|
traceN=Exp(3).traceN;
|
|
end
|
|
plot(plotAxes,t,g);hold(plotAxes,'on');
|
|
plot(plotAxes,tser,rawData,'g*');
|
|
plot(plotAxes,t,gSlow,'y');plot(plotAxes,t,gFast,'r');
|
|
hold(plotAxes,'off');
|
|
|
|
try for i=1:length(Exp(expN).hOL(:)),set(Exp(expN).hOL(i),'color',[0 0 1]); end, catch, end %ZoneRelated
|
|
Exp(expN).hOL(traceN)=plot(OLaxes,t,g);hold on;
|
|
set(Exp(expN).hOL(traceN),'color',[1 0 0])
|
|
Exp(expN).hOLb(traceN)=plot(OLaxes,tser,rawData,'g*');
|
|
|
|
%Added for Composite Plot utility [C] 170419
|
|
Exp(expN).ll(traceN)= l; Exp(expN).rr(traceN)= r; Exp(expN).kk(traceN)= K;
|
|
%************************************************
|
|
|
|
catch
|
|
%{
|
|
g = K ./ (1 + exp(-r.* (t - l )));
|
|
if K==0||r==0||l==0, g(1:200)=1;end
|
|
tser=(scan(1,plateNum).plate(1).t0Series(:));
|
|
rawData= scan(1,plateNum).plate(1).intens(indx,:)/scan(1,plateNum).plate(1).Ag(indx);
|
|
plot(plotAxes, plot(t,g),hold on,plot(tser,rawData,'g*'),hold off);
|
|
plot(OLaxes, plot(t,g),hold on,plot(tser,rawData,'g*');
|
|
%}
|
|
end %trycatch
|
|
%Get the DM agar description
|
|
if expN==1,DMstr=char(get(ghandles.DM1,'string'));end
|
|
if expN==2,DMstr=char(get(ghandles.DM2,'string'));end
|
|
if expN==3,DMstr=char(get(ghandles.DM3,'string'));end
|
|
|
|
gene=MP(1,MPsel).genename{1,1}(indx); orf=MP(1,MPsel).orf{1,1}(indx);
|
|
spec=MP(1,MPsel).specifics{1,1}(indx); %orfrep=MP(1,plateNum).orfRep{1,1}(indx);
|
|
tPtStr=strcat('T=', num2str(scan(1,plateNum).plate(1).t0Series(tPtSel)));
|
|
geneOrfstr= strcat(gene,'_',orf,'_','r',num2str(plateLoc(1)),'c',num2str(plateLoc(2)),'_',tPtStr);
|
|
grfgenestr= strcat(gene,'_',orf,'_','r',num2str(plateLoc(1)),'c',num2str(plateLoc(2)));
|
|
selGnOrf= grfgenestr; %added for EZdestComp.m and EZmDayTrend.m
|
|
%graphStr=strcat(grfgenestr,'_','L=',num2str(l),'_','r=',num2str(r),'_','K=',num2str(K));
|
|
graphStr=strcat(grfgenestr,'_','L=',Lstr,'_','r=',rstr,'_','K=',Kstr);
|
|
spotDescrip=strcat(graphStr,'->',DMstr);
|
|
|
|
xp=char(Exp(expN).Dexp(DexpN).resDir);
|
|
if ispc,
|
|
slashPos=strfind(char(Exp(expN).Dexp(DexpN).resDir),'\');
|
|
else
|
|
slashPos=strfind(char(Exp(expN).Dexp(DexpN).resDir),'/');
|
|
end
|
|
|
|
startPos=slashPos(length(slashPos)-2) +1;
|
|
endPos=(slashPos(length(slashPos)) -1);
|
|
expStr= {xp(startPos:endPos)};
|
|
|
|
Exp(expN).hOLname(traceN)= spotDescrip; %ZoneRelated %graphStr; %ghandles.Exp(expN).hOLname(traceN)= graphStr;
|
|
Exp(expN).hOLexpNm(traceN)= expStr; %ghandles.Exp(expN).hOLexpNm(traceN)= expStr;
|
|
Exp(expN).hOLresDir(traceN)= {Exp(expN).Dexp(DexpN).resDir};
|
|
Exp(expN).hOLplateNum(traceN)= plateNum;
|
|
|
|
%traceData= vertcat(get(Exp(OLay).hOL(traceN),'XData'),get(ghandles.Exp(OLay).hOL(traceN),'YData'));
|
|
|
|
if expN==1,set(ghandles.GeneOrfLoc1,'string',geneOrfstr);end % Displays the value.
|
|
if expN==2,set(ghandles.GeneOrfLoc2,'string',geneOrfstr);end
|
|
if expN==3,set(ghandles.GeneOrfLoc3,'string',geneOrfstr);end
|
|
if expN==1,set(ghandles.graphStrLoc1,'string',spotDescrip);end %graphStr);end % Displays the value.
|
|
if expN==2,set(ghandles.graphStrLoc2,'string',spotDescrip);end %graphStr);end
|
|
if expN==3,set(ghandles.graphStrLoc3,'string',spotDescrip);end %graphStr);end
|
|
%************************* ********************* ***************************
|
|
try
|
|
if expN==1, %&& get(ghandles.rotPB1,'value')~=1
|
|
try if length(char(Exp(expN).hOLname(traceN)))>40,set(ghandles.OLay1,'FontSize',8);end, catch end
|
|
set(ghandles.OLay1,'string', Exp(expN).hOLname(traceN));
|
|
try if length(char(Exp(expN).hOLexpNm(traceN)))>40,set(ghandles.OLexp1,'FontSize',8);end, catch end
|
|
set(ghandles.OLexp1,'string',Exp(expN).hOLexpNm(traceN));
|
|
end
|
|
if expN==2 %&& get(ghandles.rotPB2,'value') ~=1
|
|
try if length(char(Exp(expN).hOLname(traceN)))>40,set(ghandles.OLay2,'FontSize',8);end, catch end
|
|
set(ghandles.OLay2,'string', Exp(expN).hOLname(traceN));
|
|
try if length(char(Exp(expN).hOLexpNm(traceN)))>40,set(ghandles.OLexp2,'FontSize',8);end, catch end
|
|
set(ghandles.OLexp2,'string',Exp(expN).hOLexpNm(traceN));
|
|
end
|
|
if expN==3 %&& get(ghandles.rotPB3,'value') ~=1
|
|
try if length(char(Exp(expN).hOLname(traceN)))>40,set(ghandles.OLay3,'FontSize',8);end, catch end
|
|
set(ghandles.OLay3,'string', Exp(expN).hOLname(traceN));
|
|
try if length(char(Exp(expN).hOLexpNm(traceN)))>40,set(ghandles.OLexp3,'FontSize',8);end, catch end
|
|
set(ghandles.OLexp3,'string',Exp(expN).hOLexpNm(traceN));
|
|
end
|
|
catch
|
|
end
|
|
|
|
%*******************************************************
|
|
if expN==1
|
|
zonesel=1;
|
|
set(ghandles.zoneRad1,'value',1)
|
|
set(ghandles.zoneRad2,'value',0)
|
|
set(ghandles.zoneRad3,'value',0)
|
|
orfLstSel=get(ghandles.GeneOrfTog,'value');
|
|
if orfLstSel==1
|
|
set(ghandles.listboxGnOrf,'string',Exp(1).Dexp(DexpN).srtOrfLst)
|
|
else
|
|
set(ghandles.listboxGnOrf,'string',Exp(1).Dexp(DexpN).srtGnLst)
|
|
end
|
|
end
|
|
|
|
if expN==2
|
|
zonesel=2;
|
|
set(ghandles.zoneRad2,'value',1)
|
|
set(ghandles.zoneRad1,'value',0)
|
|
set(ghandles.zoneRad3,'value',0)
|
|
orfLstSel=get(ghandles.GeneOrfTog,'value');
|
|
if orfLstSel==1
|
|
set(ghandles.listboxGnOrf,'string',Exp(2).Dexp(DexpN).srtOrfLst)
|
|
else
|
|
set(ghandles.listboxGnOrf,'string',Exp(2).Dexp(DexpN).srtGnLst)
|
|
end
|
|
end
|
|
|
|
if expN==3
|
|
zonesel=3;
|
|
set(ghandles.zoneRad3,'value',1)
|
|
set(ghandles.zoneRad2,'value',0)
|
|
set(ghandles.zoneRad1,'value',0)
|
|
orfLstSel=get(ghandles.GeneOrfTog,'value');
|
|
if orfLstSel==1
|
|
set(ghandles.listboxGnOrf,'string',Exp(3).Dexp(DexpN).srtOrfLst)
|
|
else
|
|
set(ghandles.listboxGnOrf,'string',Exp(3).Dexp(DexpN).srtGnLst)
|
|
end
|
|
end
|
|
|
|
Exp(expN).Trace(traceN).UsrGLB= geneOrfstr;
|
|
Exp(expN).Trace(traceN).dmSel= pertSel;
|
|
Exp(expN).Trace(traceN).DexpN= DexpN;
|
|
Exp(expN).Trace(traceN).Dexp(DexpN).DM(pertSel).UsrLvals= l;
|
|
Exp(expN).Trace(traceN).Dexp(DexpN).DM(pertSel).UsrKvals= K;
|
|
Exp(expN).Trace(traceN).Dexp(DexpN).DM(pertSel).Usrrvals= r;
|
|
|
|
%**************************************************************
|
|
|
|
catch
|
|
msg='NotImage'
|
|
end % trycatch expN<4 datatip selection from Image (not from an OverLay Plot)
|
|
end %if ~exist('OLay','var')
|
|
%******************************************************************************************
|
|
%Write Selected Trace Info to OLAY header********************+++++++++++++++++*************
|
|
try
|
|
OLayTest=OLay<4
|
|
msg='OLay'
|
|
%make all traces blue
|
|
for i=1:length(Exp(OLay).hOL(:))
|
|
try set(Exp(OLay).hOL(i),'color',[0 0 1]), catch end
|
|
end
|
|
|
|
%if get(ghandles.rotPB1,'value')~=1,
|
|
for i=1:length(Exp(OLay).hOL(:))
|
|
htargetAxes
|
|
Exp(OLay).hOL(i)
|
|
if htargetAxes==Exp(OLay).hOL(i)
|
|
if OLay==1 && get(ghandles.rotPB1,'value')~=1,
|
|
set(htargetAxes,'color',[1 0 0])
|
|
try if length(char(Exp(OLay).hOLname(i)))>40,set(ghandles.OLay1,'FontSize',8);end, catch, end
|
|
set(ghandles.OLay1,'string', Exp(OLay).hOLname(i));
|
|
traceLab= char(Exp(OLay).hOLname(i));
|
|
try if length(char(Exp(OLay).hOLexpNm(i)))>40,set(ghandles.OLexp1,'FontSize',8);end, catch, end
|
|
set(ghandles.OLexp1,'string',Exp(OLay).hOLexpNm(i));
|
|
OLresDir= Exp(OLay).hOLresDir(i);
|
|
Exp(OLay).hOLplateNum(i)= Exp(expN).Dexp(DexpN).plateNum %bug fix for OLay "chrono' RF_cmp( ) trend
|
|
plateNum= Exp(expN).Dexp(DexpN).plateNum
|
|
OLplateNum= Exp(OLay).hOLplateNum(i);
|
|
seltraceN=i;
|
|
|
|
end
|
|
if OLay==2 && get(ghandles.rotPB2,'value') ~=1
|
|
set(htargetAxes,'color',[1 0 0])
|
|
try if length(char(Exp(OLay).hOLname(i)))>40,set(ghandles.OLay2,'FontSize',8);end, catch, end
|
|
set(ghandles.OLay2,'string', Exp(OLay).hOLname(i));
|
|
traceLab= char(Exp(OLay).hOLname(i));
|
|
try if length(char(Exp(OLay).hOLexpNm(i)))>40,set(ghandles.OLexp2,'FontSize',8);end, catch, end
|
|
set(ghandles.OLexp2,'string',Exp(OLay).hOLexpNm(i));
|
|
OLresDir= Exp(OLay).hOLresDir(i);
|
|
Exp(OLay).hOLplateNum(i)= Exp(expN).Dexp(DexpN).plateNum %bug fix for OLay "chrono' RF_cmp( ) trend
|
|
plateNum= Exp(expN).Dexp(DexpN).plateNum
|
|
OLplateNum= Exp(OLay).hOLplateNum(i);
|
|
seltraceN=i;
|
|
end
|
|
if OLay==3 && get(ghandles.rotPB3,'value') ~=1
|
|
set(htargetAxes,'color',[1 0 0])
|
|
try if length(char(Exp(OLay).hOLname(i)))>40,set(ghandles.OLay3,'FontSize',8);end, catch, end
|
|
set(ghandles.OLay3,'string', Exp(OLay).hOLname(i));
|
|
traceLab= char(Exp(OLay).hOLname(i));
|
|
try if length(char(Exp(OLay).hOLexpNm(i)))>40,set(ghandles.OLexp3,'FontSize',8);end, catch, end
|
|
set(ghandles.OLexp3,'string',Exp(OLay).hOLexpNm(i));
|
|
OLresDir= Exp(OLay).hOLresDir(i);
|
|
Exp(OLay).hOLplateNum(i)= Exp(expN).Dexp(DexpN).plateNum %bug fix for OLay "chrono' RF_cmp( ) trend
|
|
plateNum= Exp(expN).Dexp(DexpN).plateNum
|
|
OLplateNum= Exp(OLay).hOLplateNum(i);
|
|
seltraceN=i;
|
|
end
|
|
Exp(OLay).seltraceN=seltraceN;
|
|
else
|
|
msg='Cant Find trace'
|
|
end
|
|
|
|
|
|
end % => for i=1:length(Exp(OLay).hOL(:))
|
|
|
|
%Extract row and col values from stored trace label for dest compare plots(EZdestComp)
|
|
%if a RFcmp_ is selected Need alternate method.
|
|
%if the Composite button is active, Need yet another method.
|
|
try
|
|
tracename=char(Exp(OLay).hOLname(seltraceN))
|
|
|
|
pos_= strfind(tracename,'_')
|
|
rxcy= tracename(pos_(2):pos_(3))
|
|
cindx= strfind(rxcy,'c')
|
|
rindx= strfind(rxcy,'r')
|
|
LBr= str2num(rxcy((rindx+1):cindx-1))
|
|
LBc= str2num(tracename((pos_(2)+cindx): pos_(3)-1))
|
|
indx=((LBr-1)*24) +LBc
|
|
grfgenestr= tracename(1:pos_(3)-1)
|
|
scan= Exp(OLay).Dexp(DexpN).scan;
|
|
EZdatatip=2;
|
|
try
|
|
tracename=char(Exp(OLay).hOLname(seltraceN))
|
|
EZdatatip=2;
|
|
catch
|
|
end
|
|
catch
|
|
msg='Not from an OLay selected trace'
|
|
end
|
|
|
|
|
|
catch
|
|
msg='Not in OLay frame-axis 0'
|
|
end %=> try for Write Selected Trace Info to OLAY header******
|
|
|
|
%HIDE HIDE HIDE ---------------------------------------------------
|
|
%HIDE selected plot trace****rotPBx used for 'Hide'****************
|
|
try
|
|
OLayTest=OLay<4
|
|
msg='OLay'
|
|
OLay
|
|
|
|
if get(ghandles.rotPB1,'value') ==1 && OLay==1,
|
|
%make all traces blue
|
|
for i=1:length(Exp(OLay).hOL(:))
|
|
set(Exp(OLay).hOL(i),'color',[0 0 1])
|
|
end
|
|
|
|
for i=1:length(Exp(OLay).hOL(:))
|
|
if htargetAxes==Exp(OLay).hOL(i)
|
|
hidAx1traceN=i
|
|
set(Exp(OLay).hOL(i),'Visible','off')
|
|
set(Exp(OLay).hOLb(i),'Visible','off')
|
|
for j=1:length(Exp(OLay).hOL(:))
|
|
if isequal(get(Exp(OLay).hOL(j),'Visible'),'on'), maxhN= j; end
|
|
end
|
|
end
|
|
if htargetAxes==Exp(OLay).hOL(i), break;end
|
|
end
|
|
set(Exp(OLay).hOL(maxhN),'color',[1 0 0]) %Set latest trace red
|
|
set(Exp(OLay).hOLb(maxhN),'color',[0 1 0])
|
|
if OLay==1
|
|
try if length(char(Exp(OLay).hOLname(maxhN)))>40,set(ghandles.OLay1,'FontSize',8);end, catch, end
|
|
set(ghandles.OLay1,'string', Exp(OLay).hOLname(maxhN));
|
|
traceLab= char(Exp(OLay).hOLname(maxhN));
|
|
try if length(char(Exp(OLay).hOLexpNm(maxhN)))>40,set(ghandles.OLexp1,'FontSize',8);end, catch, end
|
|
set(ghandles.OLexp1,'string',Exp(OLay).hOLexpNm(maxhN));
|
|
OLresDir= Exp(OLay).hOLresDir(maxhN);
|
|
OLplateNum= Exp(OLay).hOLplateNum(maxhN);
|
|
end
|
|
|
|
end
|
|
|
|
%------HIDE 22222222222222222-----
|
|
if get(ghandles.rotPB2,'value')==1 && OLay==2, %
|
|
for j=1:length(Exp(OLay).hOL(:)) %Set all traces blue
|
|
try set(Exp(OLay).hOL(i),'color',[0 0 1]), catch, end
|
|
end
|
|
|
|
for i=1:length(Exp(OLay).hOL(:))
|
|
if htargetAxes==Exp(OLay).hOL(i)
|
|
hidAx2traceN=i
|
|
set(Exp(OLay).hOL(i),'Visible','off')
|
|
set(Exp(OLay).hOLb(i),'Visible','off')
|
|
for j=1:length(Exp(OLay).hOL(:))
|
|
try if isequal(get(Exp(OLay).hOL(j),'Visible'),'on'), maxhN= j; end, catch end
|
|
end
|
|
end
|
|
if htargetAxes==Exp(OLay).hOL(i), break;end
|
|
end
|
|
set(Exp(OLay).hOL(maxhN),'color',[1 0 0]) %Set latest trace red
|
|
set(Exp(OLay).hOLb(maxhN),'color',[0 1 0])
|
|
if OLay==2
|
|
try if length(char(Exp(OLay).hOLname(maxhN)))>40,set(ghandles.OLay2,'FontSize',8);end, catch, end
|
|
set(ghandles.OLay2,'string', Exp(OLay).hOLname(maxhN));
|
|
traceLab= char(Exp(OLay).hOLname(maxhN));
|
|
try if length(char(Exp(OLay).hOLexpNm(maxhN)))>40,set(ghandles.OLexp2,'FontSize',8);end, catch, end
|
|
set(ghandles.OLexp2,'string',Exp(OLay).hOLexpNm(maxhN));
|
|
OLresDir= Exp(OLay).hOLresDir(maxhN);
|
|
OLplateNum= Exp(OLay).hOLplateNum(maxhN);
|
|
end
|
|
end %if rotPB2 ....==1
|
|
|
|
%------HIDE 33333333333333-----
|
|
if get(ghandles.rotPB3,'value') ==1 && OLay==3,
|
|
%make all traces blue
|
|
for i=1:length(Exp(OLay).hOL(:))
|
|
try set(Exp(OLay).hOL(i),'color',[0 0 1]), catch, end
|
|
end
|
|
|
|
for i=1:length(Exp(OLay).hOL(:))
|
|
if htargetAxes==Exp(OLay).hOL(i)
|
|
hidAx3traceN=i
|
|
set(Exp(OLay).hOL(i),'Visible','off')
|
|
set(Exp(OLay).hOLb(i),'Visible','off')
|
|
for j=1:length(Exp(OLay).hOL(:))
|
|
try if isequal(get(Exp(OLay).hOL(j),'Visible'),'on'), maxhN= j; end, catch, end
|
|
end
|
|
end
|
|
if htargetAxes==Exp(OLay).hOL(i), break;end
|
|
end
|
|
set(Exp(OLay).hOL(maxhN),'color',[1 0 0]) %Set latest trace red
|
|
set(Exp(OLay).hOLb(maxhN),'color',[0 1 0])
|
|
if OLay==3
|
|
try if length(char(Exp(OLay).hOLname(maxhN)))>40,set(ghandles.OLay3,'FontSize',8);end, catch, end
|
|
set(ghandles.OLay3,'string', Exp(OLay).hOLname(maxhN));
|
|
traceLab= char(Exp(OLay).hOLname(maxhN));
|
|
try if length(char(Exp(OLay).hOLexpNm(maxhN)))>40,set(ghandles.OLexp3,'FontSize',8);end, catch, end
|
|
set(ghandles.OLexp3,'string',Exp(OLay).hOLexpNm(maxhN));
|
|
OLresDir= Exp(OLay).hOLresDir(maxhN);
|
|
OLplateNum= Exp(OLay).hOLplateNum(maxhN);
|
|
end
|
|
|
|
end
|
|
|
|
destcompMsg= 'Olay';
|
|
|
|
catch
|
|
msg='Not in OLay frame-axis 1'
|
|
end
|
|
|
|
|
|
|
|
|
|
%**********************************************************************************
|
|
|
|
NoOLay=0;
|
|
try
|
|
OLay
|
|
expN=OLay
|
|
EZdatatip= 2
|
|
catch
|
|
NoOLay=1;
|
|
EZdatatip=1;
|
|
end
|
|
|
|
if get(ghandles.spotTog,'value')==1 && NoOLay
|
|
OLresDir= Exp(expN).Dexp(DexpN).resDir;
|
|
OLplateNum=plateNum;
|
|
imLoc= [picLoc1(2), picLoc1(1)];
|
|
EZspotview(expN,DexpN, imLoc,OLresDir,OLplateNum,NoOLay)
|
|
end
|
|
|
|
%*****GraphicPertibationComparison**15_821*OR Chrono Day Comparison******************
|
|
%EZdatatip=1;
|
|
if strcmpi(Exp(expN).DexpType,'single')||...
|
|
strcmpi(Exp(expN).DexpType,'multi')
|
|
%************
|
|
EZdestComp %*
|
|
%************
|
|
elseif strcmpi(Exp(expN).DexpType,'chrono') && ...
|
|
length(Exp(expN).Dexp)>1
|
|
%*************
|
|
EZmDayTrend %**
|
|
%*************
|
|
end
|
|
%********************************
|
|
% spotTog && ~Hide && Olay Capture spot location for spotview May need to
|
|
% add DexpN BUT the OLresDir likely get spotview to where it needs to go.
|
|
try
|
|
if exist('OLay') %User clicked on an Overlay
|
|
if get(ghandles.spotTog,'value')==1 && get(ghandles.rotPB1,'value') ~=1 && OLay<4
|
|
msg='OLay with SpotTog On and Hide off'
|
|
pos_=strfind(traceLab,'_')
|
|
rcStr=traceLab(pos_(2)+1:pos_(3)-1)
|
|
cPos=findstr(rcStr,'c');
|
|
rUsr=str2num(rcStr(2:cPos-1));
|
|
cUsr=str2num(rcStr(cPos+1:end));
|
|
imLoc= [cUsr, (17-rUsr)]; %picLoc1 %transform horz user data to vert image for picLocation data
|
|
OLresDir %=Exp(expN).hOLresDir(traceN);
|
|
OLplateNum %=Exp(expN).hOLplateNum(traceN);
|
|
%********************************************************
|
|
EZspotview(expN, imLoc,OLresDir,OLplateNum,NoOLay) %*
|
|
%********************************************************
|
|
end
|
|
end
|
|
catch
|
|
end
|
|
[output_txt]=datatipp(obj,event_obj);
|
|
%*********************HeatMap Text Field*********************************
|
|
try
|
|
ll=num2str(l);
|
|
if length(ll)>5,htl= ll(1:5);else htl=ll;end
|
|
catch
|
|
htl=' ';
|
|
end
|
|
try
|
|
kk=num2str(K);
|
|
if length(kk)>5,htk= kk(1:5);else htk=kk;end
|
|
catch
|
|
htk=' ';
|
|
end
|
|
try
|
|
rr=num2str(r);
|
|
if length(rr)>5,htr= rr(1:5);else htr=rr;end
|
|
catch
|
|
htr=' ';
|
|
end
|
|
|
|
try
|
|
n1= num2str(Exp(expN).HtMpIntN1(indx)); %num2str(Exp(expN).Dexp(DexpN).HtMpIntN1(indx));
|
|
if length(n1)>5,N1= n1(1:5);else N1=n1; end
|
|
htN1=strcat('_N1=',N1);
|
|
catch
|
|
htN1=' ';
|
|
end
|
|
|
|
try
|
|
n2= num2str(Exp(expN).HtMpIntN2(indx)); %num2str(Exp(expN).Dexp(DexpN).HtMpIntN2(indx));
|
|
if length(n2)>5,N2= n2(1:5);else N2=n2; end
|
|
htN2=strcat('_N2=',N2);
|
|
catch
|
|
htN2=' ';
|
|
end
|
|
if Exp(expN).htmapPBsel==1, htmapStr= strcat('K= ',htk); end
|
|
if Exp(expN).htmapPBsel==2, htmapStr= strcat('r= ',htr); end
|
|
|
|
try
|
|
if Exp(expN).htmapPBsel==0 || Exp(expN).htmapPBsel>2
|
|
htmapStr=strcat('L= ',htl, htN1,htN2)
|
|
if expN==1,set(ghandles.HtMapVals1,'string',htmapStr);end
|
|
if expN==2,set(ghandles.HtMapVals2,'string',htmapStr);end
|
|
if expN==3,set(ghandles.HtMapVals3,'string',htmapStr);end
|
|
end
|
|
catch
|
|
end
|
|
|
|
try
|
|
if Exp(expN).htmapPBsel==1 || Exp(expN).htmapPBsel==2
|
|
%htmapStr=strcat('L= ',htl, htN1,htN2)
|
|
if expN==1,set(ghandles.HtMapVals1,'string',htmapStr);end
|
|
if expN==2,set(ghandles.HtMapVals2,'string',htmapStr);end
|
|
if expN==3,set(ghandles.HtMapVals3,'string',htmapStr);end
|
|
end
|
|
catch
|
|
end
|
|
|
|
%datacursormode(gcf)
|
|
%**********************************************Test Area
|
|
%Added 18_0105 to define RFcmpGFlg for EZmDayTrend.m when an Image spot
|
|
%is clicked
|
|
%try
|
|
%listboxGnOrf=get(handles.listboxGnOrf,'string');
|
|
%selGnOrf=listboxGnOrf(usrInxSel);
|
|
tempLB= str2mat(selGnOrf)
|
|
RFcmpGFlg=0;
|
|
if isequal(tempLB(4:6),'cmp'), RFnum= str2double(tempLB(3));
|
|
elseif isequal(tempLB(3:6),'cmpG'), RFcmpGFlg=1;
|
|
elseif isequal(tempLB(3:6),'cmpP'), RFcmpGFlg=1; %I beleive handling will be the same as RFcmpG
|
|
end
|
|
%catch
|
|
%end |