%  overplot_etl_panels 
% bypassing, to plor processed version where avail
if 1 == 1
    overplot_etl_flux_panels
else
%%%% get some (all?) user-supplied params
etitle = 'ETL: red ';
ecolor='red';
%
%%%% get all the data first
% truncate as you load, for better auto-axis ranges
%
% %get minute etl data


load etl1h.mat;
etl.yday=etl.mday-day1;    
iidx=find(etl.yday > (pmaxx - daystoplot));
% fprintf('etl: %d cut to %d\n', length(etl.yday),...
%     length(iidx));
etl=structtrunc(etl,iidx);



%%%% Now plot 
%%% add editing clauses as needed
%
% 1.atmp hrh  2.bpr prc  3.sst sal  4 lwr swr  5. wind
%% 
figure(1);  
% atmp, hrh
subplot(2,1,1);    %atmp
line(etl.yday,etl.atmp,'Color',ecolor,'LineStyle','--')
ylabel('atmp');
hold on
title([titlemain atitle stitle etitle]);
ax=axis;
ax(3)=min([ax(3); etl.atmp]);
axis([ pminx pmaxx ax(3:4) ]);

subplot(2,1,2);  %hrh
line(etl.yday,etl.hrh,'Color',ecolor,...
    'LineStyle','--')
ax=axis;
ax(3)=min([ax(3); etl.hrh]);
axis([ pminx pmaxx ax(3:4)]);



%% sst & sal
figure(2);  
subplot(2,1,1);   %sst
hold on
line(etl.yday,etl.sst,'Color',ecolor,'LineStyle',':');
 ax=axis;
 axis([ pminx pmaxx ax(3:4)]);
title([titlemain atitle stitle etitle]);
% subplot(2,1,2);  %sal
% hold on
% gsal=find(tsg.sal > 20);
% line(tsg.yday(gsal),tsg.sal(gsal),'Color',ecolor,'LineStyle',...
%     '--');
% 
% %      if exist('tsgH','var'),
% %         line(tsgH.yday,tsgH.sal,'r.'); end
% ax=axis;
% axis([ pminx pmaxx ax(3:4)]);

%% 
figure(3);  % bpr & prc
subplot(2,1,1); %bpr
hold on
line(etl.yday,etl.bpr,'Color',ecolor,'LineStyle',':');
 ax=axis;
 ax(4)=max([ax(4); etl.bpr]);
 axis([ pminx pmaxx ax(3:4)]);
title([titlemain atitle stitle etitle]);

subplot(2,1,2);    % rain
hold on
line(etl.yday,etl.rainrate,'Color',ecolor,...
    'LineStyle','--');
ax=axis;
axis([ pminx pmaxx -1 ax(4)]);

%% swr, lwr
figure(4);
subplot(2,1,1);  % swr
hold on
% gv=find(etl.swr > -2);
% line(etl.yday(gv),etl.swr(gv),'Color',ecolor, 'LineStyle',...
%     '--');
line(etl.yday,etl.swrKz,'Color',ecolor, 'LineStyle', '--');
ax=axis;
axis([ pminx pmaxx ax(3:4)]);
title([titlemain atitle stitle etitle]);

subplot(2,1,2);    % lwr
hold on
line(etl.yday,etl.lwrKz,'Color',ecolor,'LineStyle','--');
% ,...     'Marker','.','MarkerSize',2);
ax=axis;
axis([ pminx pmaxx ax(3) ax(4)]);


% %% wind
% figure(5);
% subplot(2,1,1);   % wind speed wnds
% line(etl.yday,etl.wnds,'Color',ecolor,'LineStyle','--');
% ax=axis;
% axis([ pminx pmaxx ax(3:4)]);
% title([titlemain atitle stitle etitle]);
% 
% subplot(2,1,2);  %wdir
% line(etl.yday,(etl.wndd),'Color',ecolor,'LineStyle','--');
% ax=axis;
% axis([ pminx pmaxx ax(3:4)]);
end
