NCCOOS Trac Projects: Top | Web | Platforms | Processing | Viz | Sprints | Sandbox | (Wind)

root/DPWavesProc/trunk/DPWavesProc/test_code/nortek_Winfo_plot_compare.m

Revision 225 (checked in by gdusek, 15 years ago)

Re-organized directory structure and cleaned up some code.

Line 
1 function [fig_sigh,fig_pp,fig_dp,fig_dd]=nortek_Winfo_plot(Winfo);
2
3 %This function takes the wave info (sigH, peak period, direction of peak and dominant direction
4 %for a series of bursts and plots it as a function of time
5
6
7 %plot sig wave height
8 scrsz = get(0,'ScreenSize');
9 fig_sigh=figure('Position',[scrsz]);
10 h1=plot(Winfo.time,Winfo.hsig(1,:),'b.-');
11 hold on
12 h1a=plot(Winfo.time,Winfo.hconf(1,1:2:end),'b--');
13 plot(Winfo.time,Winfo.hconf(1,2:2:end),'b--');
14 h2=plot(Winfo.time,Winfo.hsig(2,:),'r.-');
15 h2a=plot(Winfo.time,Winfo.hconf(2,1:2:end),'r--');
16 plot(Winfo.time,Winfo.hconf(2,2:2:end),'r--');
17 h3=plot(Winfo.time,Winfo.hsig(3,:),'k.-');
18
19 datetick('x',15,'keepticks');
20 legend([h1,h1a,h2,h2a,h3],'EMEP','EMEP 95% confidence','IMLM','IMLM 95% confidence','nortek','location','best');
21 title(['Significant Wave Height starting on ',datestr(Winfo.time(:,1),0)]);
22 xlabel('time');
23 ylabel('Wave Height (m)');
24
25 %plot peak period
26 fig_pp=figure('Position',[scrsz]);
27 h1=plot(Winfo.time,Winfo.peakP(1,:),'b.-');
28 hold on
29 h2=plot(Winfo.time,Winfo.peakP(2,:),'r.-');
30 h3=plot(Winfo.time,Winfo.peakP(3,:),'k.-');
31
32 datetick('x',15,'keepticks');
33 legend([h1, h2, h3],'EMEP','IMLM','nortek','location','best');
34 title(['Peak Period starting on ',datestr(Winfo.time(:,1),0)]);
35 xlabel('time');
36 ylabel('Period (seconds)');
37
38 %plot dir of peak period
39 fig_dp=figure('Position',[scrsz]);
40 h1=plot(Winfo.time,Winfo.dirP(1,:),'b.-');
41 hold on
42 h2=plot(Winfo.time,Winfo.dirP(2,:),'r.-');
43 h3=plot(Winfo.time,Winfo.dirP(3,:),'k.-');
44
45 datetick('x',15,'keepticks');
46 legend([h1, h2, h3],'EMEP','IMLM','nortek','location','best');
47 title(['Direction of Peak Period starting on ',datestr(Winfo.time(:,1),0)]);
48 xlabel('time');
49 ylabel('Direction (Degrees True)');
50
51 %plot the dominant direction
52
53 fig_dd=figure('Position',[scrsz]);
54 h1=plot(Winfo.time,Winfo.Ddir(1,:),'b.-');
55 hold on
56 h2=plot(Winfo.time,Winfo.Ddir(2,:),'r.-');
57 h3=plot(Winfo.time,Winfo.Ddir(3,:),'k.-');
58
59 datetick('x',15,'keepticks');
60 legend([h1, h2, h3],'EMEP','IMLM','nortek','location','best');
61 title(['Dominant Direction starting on ',datestr(Winfo.time(:,1),0)]);
62 xlabel('time');
63 ylabel('Direction (Degrees True)');
64
Note: See TracBrowser for help on using the browser.