em_dolly('L:\Hatteras09\853NorthSurface\8533pt-a.nc','L:\Hatteras09\853NorthSurface\8533pt-ashift.nc','fix_time','yes')%add four days ncpt=netcdf('L:\Hatteras09\853NorthSurface\8533pt-ashift.nc'); jd_pt=ncpt{'time'}(:) + (ncpt{'time2'}(:)/3600/1000/24); T_28_pt=ncpt{'T_28'}(:); T_28_pt(T_28_pt>=1e35)=nan; ncsc=netcdf('X:\data\hatteras09\BBV_reviewed\8532sc-a.nc'); jd_sc=ncsc{'time'}(:) + (ncsc{'time2'}(:)/3600/1000/24); T_28_sc=ncsc{'T_28'}(:); T_28_sc(T_28_sc>=1e35)=nan; ncmcb=netcdf('X:\data\hatteras09\BBV_reviewed\8531mc-a.nc'); jd_mcb=ncmcb{'time'}(:) + (ncmcb{'time2'}(:)/3600/1000/24); T_28_mcb=ncmcb{'T_28'}(:); T_28_mcb(T_28_mcb>=1e35)=nan; ncmc=netcdf('X:\data\hatteras09\BBV_reviewed\8541mc-a.nc'); jd_mc=ncmc{'time'}(:) + (ncmc{'time2'}(:)/3600/1000/24); T_28_mc=ncmc{'T_28'}(:); T_28_mc(T_28_mc>=1e35)=nan; %% The SQUEEZE clf; plot(new_jd_sc,T_28_sc(320:end),'g');hold on; plot(jd_pt(1:26970),T_28_pt(1:26970),'r');hold on; Legend('seacat','pt') new_jd_sc=(jd_pt(1)):(93.6424/27900):(jd_pt(26970)); sc_time=floor(new_jd_sc); sc_time2=(new_jd_sc-sc_time)*3600*1000*24; sc_test=sc_time + sc_time2/3600/1000/24; val=new_jd_sc-sc_test; trunc_cdf('L:\Hatteras09\853NorthSurface\8532sc-a.nc','L:\Hatteras09\853NorthSurface\8532sc-afix.nc',[320 28219]); ncf=netcdf('L:\Hatteras09\853NorthSurface\8532sc-afix.nc','w'); ncf{'time'}(:)=sc_time; ncf{'time2'}(:)=sc_time2; ncf.history(:)=['time records altered to fix clock error, matched to sensors on 853 surface buoy ',ncf.history(:)]; close(ncf); ncsc=netcdf('L:\Hatteras09\853NorthSurface\8532sc-afix.nc'); jd_sc=ncsc{'time'}(:) + (ncsc{'time2'}(:)/3600/1000/24); T_28_sc=ncsc{'T_28'}(:); T_28_sc(T_28_sc>=1e35)=nan; %% clf; plot(jd_sc,T_28_sc,'g');hold on; plot(jd_pt,T_28_pt,'r');hold on; plot(jd_mcb,T_28_mcb,'m');hold on; Legend('seacat','pt','microcat') ncclose