1 | function time_serie_ER_rossby_df_complet(period1, period2) |
---|
2 | % time_serie_ER_rossby_df_complet ++explication between period1 days and period2 days |
---|
3 | |
---|
4 | %+ |
---|
5 | % |
---|
6 | % .. _time_serie_ER_rossby_df_complet.m: |
---|
7 | % |
---|
8 | % ================================= |
---|
9 | % time_serie_ER_rossby_df_complet.m |
---|
10 | % ================================= |
---|
11 | % |
---|
12 | % ++ |
---|
13 | % |
---|
14 | % DESCRIPTION |
---|
15 | % =========== |
---|
16 | % |
---|
17 | % plot ++ from file :file:`eof_rossby_jjas_2006_10-30d.mat` |
---|
18 | % |
---|
19 | % EXAMPLES |
---|
20 | % ======== |
---|
21 | % |
---|
22 | % Following line read :file:`eof_rossby_jjas_2006_10-30d.mat`, plot ++and produce Postscript files :file:`time_serie_eof_ER_10-30d_part*.eps`. |
---|
23 | % |
---|
24 | % :: |
---|
25 | % |
---|
26 | % >> time_serie_ER_rossby_df_complet(10,30); |
---|
27 | % |
---|
28 | % SEE ALSO |
---|
29 | % ======== |
---|
30 | % |
---|
31 | % :ref:`olr_eof_jjas2006_rossby_df.m` |
---|
32 | % |
---|
33 | % :ref:`carte_eof_ER_1030_article.m` |
---|
34 | % |
---|
35 | % :ref:`carte_eof_ER_jjas_df.m` |
---|
36 | % |
---|
37 | % :ref:`time_serie_ER_rossby_df.m` |
---|
38 | % |
---|
39 | % TODO |
---|
40 | % ==== |
---|
41 | % |
---|
42 | % improve description |
---|
43 | % |
---|
44 | % improve file pb |
---|
45 | % |
---|
46 | % use return function |
---|
47 | % |
---|
48 | % EVOLUTIONS |
---|
49 | % ========== |
---|
50 | % |
---|
51 | % $Id$ |
---|
52 | % |
---|
53 | % - fplod 2009-02-11T16:27:34Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
54 | % |
---|
55 | % * add try/catch on opening file for reading |
---|
56 | % |
---|
57 | % - fplod 2009-02-10T14:28:00Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
58 | % |
---|
59 | % * replace ndmin by period1 and ndmax by period2 |
---|
60 | % |
---|
61 | % - fplod 2009-01-27T11:51:31Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
62 | % |
---|
63 | % * created from time_serie_ER_rossby_1030_complet.m to replace it as well as |
---|
64 | % time_serie_ER_rossby_30100_complet.m |
---|
65 | % |
---|
66 | % Days will be now written ``period1``\-``period2d`` (ex: 10-30d) in filenames. |
---|
67 | % |
---|
68 | %- |
---|
69 | |
---|
70 | global IRCAAM_ID; |
---|
71 | global IRCAAM_OD; |
---|
72 | |
---|
73 | if nargin==2 |
---|
74 | % period1 must be lower than period2 |
---|
75 | if (period1 > period2) |
---|
76 | disp(['period1 = ', int2str(period1)]); |
---|
77 | disp(['period2 = ', int2str(period2)]); |
---|
78 | error('eee : period1 must be lower than period2'); |
---|
79 | end |
---|
80 | else |
---|
81 | usage='usage : time_serie_ER_rossby_df(period1, period2)'; |
---|
82 | disp(usage); |
---|
83 | error('eee : wrong arguments numbers') |
---|
84 | end |
---|
85 | |
---|
86 | % period1 and period2 will be used in xx-yyd form in filenames |
---|
87 | df = [int2str(period1),'-',int2str(period2),'d']; |
---|
88 | clear period1; |
---|
89 | clear period2; |
---|
90 | |
---|
91 | close all; |
---|
92 | |
---|
93 | figure(1); |
---|
94 | orient('landscape') |
---|
95 | figure(2); |
---|
96 | orient('landscape') |
---|
97 | figure(3); |
---|
98 | orient('landscape') |
---|
99 | |
---|
100 | fullfilename=[IRCAAM_ID,'eof_rossby_jjas_2006_',df,'.mat']; |
---|
101 | try |
---|
102 | status=load(fullfilename,'C','olr'); |
---|
103 | catch |
---|
104 | error('eee : File %s not found\n', fullfilename); |
---|
105 | end |
---|
106 | |
---|
107 | clear fullfilename; |
---|
108 | C=status.C; |
---|
109 | olr=status.olr; |
---|
110 | clear status; |
---|
111 | |
---|
112 | olr=olr'; |
---|
113 | PC1=olr*C; |
---|
114 | |
---|
115 | time_serie_olr1=PC1(:,425); |
---|
116 | time_serie_olr2=PC1(:,424); |
---|
117 | |
---|
118 | for a=1:28; |
---|
119 | if a<12; |
---|
120 | figure(1); |
---|
121 | subplot(4,3,a); |
---|
122 | elseif a<23; |
---|
123 | figure(2); |
---|
124 | subplot(4,3,a-11); |
---|
125 | else |
---|
126 | figure(3); |
---|
127 | subplot(4,3,a-22); |
---|
128 | end; |
---|
129 | clear koro1 |
---|
130 | debut=(a-1)*122+1; |
---|
131 | fin=a*122; |
---|
132 | koro1=time_serie_olr1(debut:fin); |
---|
133 | koro2=time_serie_olr2(debut:fin); |
---|
134 | x=[1:122]'; |
---|
135 | aa=plot(x,-koro1,'r'); |
---|
136 | hold on; |
---|
137 | bb=plot(x,-koro2,'k'); |
---|
138 | % cc=legend('EOF1','EOF2') |
---|
139 | % set (cc,'fontsize',6) |
---|
140 | % legend boxoff; |
---|
141 | y=zeros(122,1); |
---|
142 | plot(x,y,'k:'); |
---|
143 | if a==2; |
---|
144 | text(0,183,['time series EOF1 and EOF2 OLR ER ' df]); |
---|
145 | elseif a==13; |
---|
146 | text(0,183,['time series EOF1 and EOF2 OLR ER ' df]); |
---|
147 | elseif a==24; |
---|
148 | text(0,183,['time series EOF1 and EOF2 OLR ER ' df]); |
---|
149 | end; |
---|
150 | title(a+1978,'FontSize',8); |
---|
151 | set (gca,'tickDir','out'); |
---|
152 | axis([1 122 -100 100]); |
---|
153 | |
---|
154 | set (gca,'YTick',[-100:20:100],'YTickLabel',[-100:20:100],'fontname','Arial','fontsize',6); |
---|
155 | set (gca,'XTick',[0:20:120],'XTickLabel',[0:20:120],'fontname','Arial','fontsize',6); |
---|
156 | end; |
---|
157 | |
---|
158 | figure(1); |
---|
159 | fullfilename=[IRCAAM_OD,'time_serie_eof_ER_',df,'_part1.eps']; |
---|
160 | print('-depsc2',fullfilename); |
---|
161 | figure(2); |
---|
162 | fullfilename=[IRCAAM_OD,'time_serie_eof_ER_',df,'_part2.eps']; |
---|
163 | print('-depsc2',fullfilename); |
---|
164 | figure(3); |
---|
165 | fullfilename=[IRCAAM_OD,'time_serie_eof_ER_',df,'_part3.eps']; |
---|
166 | print('-depsc2',fullfilename); |
---|