%PlotDeployment

close all;
clear all;
dates=['1002';'1003';'1004';'1005';'1009';'1010';'1011';'1012';'1014';'1016';'1017';'1018';'1019';'1020';'1023';'1024';'1025';'1026';'1027';'1030';'1031';'1101';'1104';'1105';'1107';'1108';'1109';'1110'];
figure; hold on;
legendString=[];
for i= 1: size(dates),
    load(strcat(dates(i,:),'.mat'));
   
   plot(PortTS,'r');hold on; plot(RefTS,'b');hold on;plot(StbdTS,'g');hold on;

end
legend('Port','Ref','Stbd');
xlabel('Time (days)');
ylabel ('%02 Sat');
title('Optode Data Oct-Nov 2009, Smooth Ridge');


figure; hold on;
legendString=[];
for i= 1: size(dates),
     load(strcat(dates(i,:),'.mat'));
   plot(PortConcTS,'r');hold on; plot(RefConcTS,'b');hold on;plot(StbdConcTS,'g');hold on;

end
legend('Port','Ref','Stbd');
xlabel('Time (days)');
ylabel ('%02 Conc (um)');
title('Optode Data Oct-Nov 2009, Smooth Ridge');



figure; hold on;
legendString=[];
%mycolor=autumn(size(dates,1));
mycolor=jet(size(dates,1));

for i= 1: size(dates),
    load(strcat(dates(i,:),'.mat'));
    %plot(PortConcTS,'Color',mycolor(i,:)); hold on;
    plot(PortConcTS,'r.'); hold on;
    legendString=[legendString;strcat(dates(i,:))];
end
legend(legendString);
xlabel('Time (days)');
ylabel ('%02 Conc');
title('Port Optode Data Oct 2009, Smooth Ridge');

refdates= ['1023';'1024';'1025';'1026';'1027';'1030';'1031';'1032';'1101';'1104';'1105';'1107';'1108';'1109';'1110';'1112'];

figure; 
figure;
legendString=[];
%mycolor=autumn(size(dates,1));
mycolor=jet(size(refdates,1));

for i= 1: size(refdates),
    load(strcat(refdates(i,:),'R.mat'));
    figure(1);plot(StbdConcTS,'Color',mycolor(i,:)); hold on;
    figure(2); plot(PortConcTS,'r');hold on; plot(StbdConcTS,'g');hold on;
    legendString=[legendString;strcat(refdates(i,:))];
end
figure(1);legend(legendString);
xlabel('Time (days)');
ylabel ('%02 Conc');
title('Stbd Optode Data Oct 2009, Smooth Ridge');

figure(2);
legend('Port','Stbd');
xlabel('Time (days)');
ylabel ('%02 Conc');
title('Optode Data Oct-Nov 2009, Smooth Ridge');


print('-dill','PortConc.ai')