
fil='../tmp/diff.nc';
egM=ncread(fil,'AGM_EG');                egM=egM(1:69);
egS=ncread(fil,'AGMSTD_EG');             egS=egS(1:69);

deM=ncread(fil,'AGM_DEFAULT');           deM=deM(1:69);
deS=ncread(fil,'AGMSTD_DEFAULT');        deS=deS(1:69);

%errplot_h([1:69],egM,egV.^0.5)

figure
 fs=12; ln=1.3; lnp=2;

subplot(3,1,1)
set(gca,'box','on','nextplot','add','fontsize',fs,'linewidth',ln,'ygrid','on','xgrid','on','ylim',[260 420], ...
        'xgrid','on','tickdir','out')
 plot(deM,'k','linewidth',lnp)
 plot(egM,'b','linewidth',lnp)

% xlabel('year')
 ylabel('diffusivity [m^2/s]')
print -depsc ../ps/diff.eps
% plot([1 69],[600 600],'r','linewidth',lnp)
% mean(deM(1:20))
% mean(egM(1:20))

%errplot_h([1:69],deM,deS.^0.5)
%errplot_hb([1:69],egM,egS.^0.5)
