/[MITgcm]/MITgcm/utils/matlab/displaytiles.m
ViewVC logotype

Contents of /MITgcm/utils/matlab/displaytiles.m

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.2 - (show annotations) (download)
Fri Jun 4 17:03:50 2004 UTC (19 years ago) by adcroft
Branch: MAIN
CVS Tags: checkpoint53f_post, checkpoint54a_pre, checkpoint55c_post, checkpoint57m_post, checkpoint57h_done, checkpoint57g_pre, checkpoint57f_post, checkpoint57j_post, checkpoint57b_post, checkpoint53d_post, checkpoint57f_pre, checkpoint55d_pre, checkpoint57g_post, checkpoint57a_post, checkpoint55j_post, checkpoint56b_post, checkpoint57h_pre, checkpoint54a_post, checkpoint55h_post, checkpoint54b_post, checkpoint57e_post, checkpoint54d_post, checkpoint56c_post, checkpoint54e_post, checkpoint55b_post, checkpoint55, checkpoint55a_post, checkpoint57c_pre, checkpoint57o_post, checkpoint55g_post, checkpoint57r_post, checkpoint57k_post, checkpoint57d_post, checkpoint55f_post, checkpoint57i_post, checkpoint57h_post, checkpoint57a_pre, checkpoint54, checkpoint57, checkpoint56, checkpoint53g_post, checkpoint57n_post, checkpoint57p_post, checkpoint57q_post, checkpoint54f_post, eckpoint57e_pre, checkpoint57c_post, checkpoint55e_post, checkpoint54c_post, checkpoint55i_post, checkpoint57l_post, checkpoint56a_post, checkpoint55d_post
Changes since 1.1: +6 -2 lines
New scripts and M6.5 compatibility issues

1 function [] = displaytiles(A)
2 % Display tiled field.
3 %
4 % Dimensions of A must be (n,n,6)
5
6 global cmin cmax
7 clf
8
9 if size(A,3)==1
10 A=tiles(A,1:6);
11 end
12
13 cmin=min(min(min(A)));
14 cmax=max(max(max(A)));
15 if isnan(cmin)
16 cmin = 0;
17 end
18 if isnan(cmax)
19 cmax = 1;
20 end
21 if cmin==cmax
22 cmax = cmin+1;
23 end
24
25 subplot(3,4,9)
26 myplot(A(:,:,1)')
27 subplot(3,4,10)
28 myplot(A(:,:,2)')
29 subplot(3,4,6)
30 myplot(A(:,:,3)')
31 subplot(3,4,7)
32 myplot(A(:,:,4)')
33 subplot(3,4,3)
34 myplot(A(:,:,5)')
35 subplot(3,4,4)
36 myplot(A(:,:,6)')
37
38
39 %Colorbar
40 subplot(3,10,30)
41 x=[0 1];
42 y=(0:63)'/63*(cmax-cmin)+cmin;
43 pcol(x,y,[y y]);
44 set(gca,'XTickLabel',[]);
45
46 function [] = myplot( Q )
47 global cmin cmax
48 pcol( Q );
49 caxis([cmin cmax])

  ViewVC Help
Powered by ViewVC 1.1.22