|
EDA365欢迎您登录!
您需要 登录 才可以下载或查看,没有帐号?注册
x
% q, X' k9 |- ~, C+ Z' N0 W) n+ f2 b
MetToolbox工具箱简介:
/ ?" i1 V/ R$ Y) {9 G& S% k/ S2 q0 P6 F2 _
1 风矢量图:0 \. o8 i$ W3 W( W: K$ L
6 u+ n, ^- u# M" w' S+ D
clc;clear;close all
P2 w' Q0 l' h5 k: F7 d2 c3 ?[x,y] = meshgrid(70:10:140,15:10:55);( V& E- y8 b; R5 |8 p2 k9 p9 E
u = cos(x).*y*10;
1 K6 d; g1 C" `5 ^ v* V2 r5 Fv = sin(x).*y*10;
& v) m& Z' v" [' n: q- O; efigure(1);
% f; ^' D& S+ \# X0 q5 j0 i% % m_proj('Equidistant Cylindrical','long',[70 140],'lat',[15 55]);
& M+ L* Z6 R+ U* h0 N/ o" L# {% m_proj('lambert','lon',[70,140],'lat',[15,55]);9 P+ s3 W8 k' U: e, T. ?% R* i% d
% ma=shaperead('F:/RMeteoInfo/data/map/bou2_4l.shp');
, c D$ E( o4 i$ q, D4 U% % m_line( [ma(:).X], [ma(:).Y],'color',[0.5,0.5,0.5]);%绘制范围内的地图
% ]6 ?% \* x7 B5 F, T, I% % m_line([ma(:).X],[ma(:).Y],'color','k');%绘制范围内的地图9 k# f5 E1 B) i: E
% m_plot([ma(:).X],[ma(:).Y],'color','k');%绘制范围内的地图& l) e: K7 a+ v9 t2 _
% hold on
8 V) o% x' c9 ^1 }- d6 Yh=quiver(x,y,u,v,0.5,'r-'); a, b9 \. K' @# q& Y
hl=quiverlegend(h,10);
8 p9 _. @6 Y' o- H' f1 H$ P! M: F6 g%设置x轴范围和刻度
/ ?) |; q5 v$ z+ Q1 B! d& aset(gca,'XLim',[70 140]);%X轴的数据显示范围" Y" ?/ N1 ]% @6 Q/ V
set(gca,'XTick',[70:10:140]);%设置要显示坐标刻度
1 F, w0 O% @4 a2 M$ r! eset(gca,'XTickLabel',[70:10:140]);%给坐标加标签 ' L) N4 p2 j1 n
%设置y轴范围和刻度$ u( p9 V% @# h) w! c8 k- Y
set(gca,'YLim',[15 55]);%X轴的数据显示范围
4 V* R3 O7 \5 S# w! tset(gca,'YTick',[15:10:55]);%设置要显示坐标刻度
! D) N6 W2 z% n$ Xset(gca,'YTickLabel',[15:10:55]);%给坐标加标签
& a1 i0 }9 E1 c. s: r
E0 g4 N2 P8 @. A) Y+ C* H7 G
+ b% N: I m$ e3 m/ m$ N
$ x; d" t0 \4 V3 s; `% ^
' C4 l1 s0 T2 N9 \" x
" ~+ V5 k2 j2 }) W j. v
2 高版本m_map工具箱指南针&比例尺:# l. p% p$ }9 ?5 u6 e
; @& q" }- j" l& X0 k0 t
clc;clear;close all
# T4 T: `/ h$ |m_proj('miller','lat',[-77 77]);
7 b9 Z7 B( s# f" im_coast('patch',[.7 1 .7],'edgecolor','none');
; ~8 X+ K4 l" K# n) S# _0 q0 U- em_grid('box','fancy','linestyle','-','gridcolor','w','backcolor',[.2 .65 1]);
- _6 |0 r7 [' G1 B. a Em_ruler([.4 .9],.3,'tickdir','out','ticklen',[.007 .007]);+ b& R/ T; T- e- J
% 需要更新m_map- \0 K5 w4 L2 K& V: p
% m_northarrow(76,48,0.8,'type',4,'aspect',1.5);
0 A+ o1 H. \8 d3 J8 vm_northarrow(-125.4,49.7,.2,'type',2);
" [) Y2 O9 x4 C8 b, o+ l% e% northarrow(76,48,0.8,'type',4,'aspect',1.5);
* Z2 r% f* m$ J* _1 \( p, L4 X/ N+ Etitle('Great Circle Routes','fontsize',14,'fontweight','bold');5 o. K+ s( k3 k3 T
set(gcf,'color','w'); % Need to do this otherwise 'print' turns the lakes black
; T) n$ u% H8 y5 ], C- Q: C% ^. |) j: F' J% {8 e! H$ E$ Y6 R% o f$ s8 H- @: U
: K# \, |9 E( j+ E8 t7 y' H4 M' b4 V" L/ Z7 D% N3 \) q' I6 t
" s% u- }/ K9 K) o- X( e& ?5 E
0 Z0 f4 a& k% l3 {3 利用Map Toolbox不同投影全球地形的绘制
/ d2 X, ~/ H$ }0 x1 A/ G* V4 u9 c
$ S! k! J0 G( n% s4 o9 _+ _clc;clear;close all( D5 c( @! q4 `
load etopo
0 R* y2 @. @3 @# M+ ^9 wload topo
- p4 K T, z, l# h: X V# z& Mfigure(1);/ U! f4 e4 X& X; Y# G
ctopo=topo(90:160,50:160);* n3 P' I& x- g
clegend=[1 70 50];+ ~3 N T! x' E/ J
worldmap(topo,topolegend);' v! I7 m6 a) x7 X1 l7 k
meshm(topo,topolegend);
- u' S: }4 ` D: B+ x+ f9 WdEMCmap(topo)% h+ i$ @4 f, ^0 @. e! H
axis off. |( u P" l5 [, P/ p8 t( b
setm(gca,'Origin',[0 105 0])
( `, M3 o9 A* Y, q! wptopo = topo; ptopo(topo<0) = 0;
8 q g4 T9 ~9 @4 k% u' |. Dptopo = 100*ptopo/(6371*1000);: A% e5 L; k# ~2 }7 R6 v N
figure(2);
2 m' R0 D( @& Baxesm('MapProjection','ortho','Origin',[0 0 15])1 y- k% w' `- j: F( \1 c
meshm(topo,topolegend,size(topo),topo/10000); 5 A: A! T% M& X+ T% n
shading interp
3 @! t6 b. X* m/ n- G4 K& N0 ddemcmap(topo)8 K* X0 a7 s! N9 i8 V; w! m
lightm(23.5,80,'Color',[1 1 0.2])2 n/ {3 `; q+ H! v
material([.6 0.8 0]);
7 l$ ?& N% ]6 R2 X+ v; o2 d K1 `lighting phong
% g8 t$ [+ t# ^8 }axis off+ G! u5 L" ^2 u6 v+ w
daspectm('km',20000)
$ K" ~4 ]! i( }3 U( [% i% w4 ^! sfigure(3);( i& X" c1 L2 i0 @/ V W" ~
axesm('MapProjection','globe','Origin',[0 105 0])8 N) |% K8 Y% d+ c P8 I* r
meshm(topo,topolegend,size(topo),topo/100000);
9 ] g1 v7 n# l/ T* ~' vshading interp0 a) f; S1 e0 B
% [lat,lon]=meshgrat(topo,topolegend);
/ U1 X' c! V* K8 C d% suRFm(lat,lon,topo,ptopo)8 a4 h8 |, _, L& z4 w
demcmap(topo)
, j. R6 V0 g* D! {lightm(23.5,20,'Color','y')6 [1 s4 Q, @7 G, {$ \. ?+ u
material([.6 1 0]);
8 A0 {, O: ]# ]- B @ K8 A" dlighting phong* L e' s, M( \; H
axis off. @8 K' P( q, T3 C* C9 P2 B( v% f
view([200 0])* ?/ V- `8 t x1 B( d
z=topo;% c8 [4 X& |' @: a' E9 J- G
figure(4);2 P3 n) ~3 F3 X. T3 k2 G
surf(z)) f. j6 G$ h Y. a; Y6 H
shading interp
% D$ D) O% m3 J% b, ~( ]" c. Kdemcmap(z)7 x2 Y/ @% R+ I( r1 a6 P, ^
view([0 90])0 L( B- r7 L$ ^8 q7 I6 }% V( _/ P
axis off8 ^% G, j; \( V* K7 [2 ^2 S
light('position',[1 180 1000],'color','w')
; H, E4 x- \ a( Pmaterial([0.6 1 0]);
2 D8 ]/ G) h0 @& alighting phong( Y1 r9 y' I7 ^# T- |9 u
* L% t2 \* o) Z
- n; f, u M3 H0 d9 X* K# J3 r7 u
7 E* U$ [* }! Y/ a9 G
9 u, w) K, p4 D+ t4 利用uniteprv合并东北三省与内蒙四个区域
8 X# \. }; b# k3 l O" r# E0 g x# T! A `, c8 {
clc;clear;close all
" S" D& s4 p6 U% ^load prvpatch;# r6 R) D( n2 b6 ~( ?' p. D3 l
figure/ {$ i4 d |/ Y3 I( \, ^
hold on) X7 O$ {: M/ Y) E
wnprv={'内蒙','黑龙江','吉林','辽宁'};! q/ Z% |! _/ G: O! q/ l+ ?, } c0 x" R
nw=1;
2 u0 R' W; |8 a& r# Qfor i=1:381 M4 R5 S' S: g! }" |3 `) @
if any(cellfun(@(x) ~isempty(strmatch(x,s(i).tag)),wnprv))7 R* M+ F' A" y" ?8 e+ G) Q( z; ]" x
disp([nw i])
+ x5 y9 L8 G* V- l8 @ if nw==17 P7 h7 l& }+ j0 z1 i: L4 l0 D- d+ X
long=s(i).long;( Y& P. j4 r" ^7 m7 @
lat=s(i).lat;! j# N- _" E* w& Q. D6 Z0 l3 e
else R0 N t) \. P6 z4 _. e3 X9 B
[long lat]=uniteprv(long,lat,s(i).long,s(i).lat);
9 C' O3 ? [6 Z7 ^* m: {( |) H end* H$ b8 O5 K; P" F$ k+ w
nw=nw+1;4 v- x0 O( L/ ?$ g7 ?$ [) S! |
end 9 S6 m2 @1 V7 W% X- a4 ]: f
plot(s(i).long,s(i).lat)8 _6 z$ m9 j0 I3 @3 c7 L# R: s
end J" j" B4 X( L% L( f" A/ r
% [long lat]=pactpt(long,lat,0.1);# ]9 F* U3 _5 n3 F' R3 G$ {. K$ ]
patch(long,lat,'m');
" o: f; L* y1 [5 i1 ^3 \8 m* ]mapnorm;- e8 H5 [7 t, V1 K& C5 ]. H
- J' T3 J, |0 C* {& e) u9 @) C( c
& l3 ?2 H% L. i
% w3 M+ C. u$ u0 Q' D3 L% \
+ v) ] O9 T, ~# m
* g, |9 K; m6 }2 {" s5 填充带条纹的等值线
I) W# K- I& l' ]. x2 E; f; [) k }- C' J. @1 _" _
clc;clear;close all F: ?# x) r8 p4 k8 z
z=peaks;; t4 x7 s) G& [" N5 R: H8 k
x=1:size(z,2);5 D, a1 b V! x; |' a/ P
y=1:size(z,1);" F5 }* e! X& C+ E U# l
cv=-8:2:8;( m! B) |0 N4 n
cmap=cusjet(10);1 ?, y5 R2 D: A! N
ifirst=0;2 Y* Z5 W3 Q: B$ {4 [$ U0 c, l
ndelta=1;% e! o2 S2 u7 a& g' H
iswbg=true;* |2 I- t ~! k! I/ |
bardir='horiz';
6 r% d: E# V5 v. b9 s% csty={'r.-',linewidth,markersize,linecolor,markeredgecolor,markerfacecolor};
* ?* z" L Y% y L% tex={ctex,nnl,ldir,csty}0 o+ g! } r) S
csty={'r.-'};& z. y# L# i8 Z
tex={-4,[100 80],1,{'r:'}; 2,[100 80],3,{'b-'}};
a' T' T; W+ [" U! K- Efigure
( }) ^2 L- c8 F3 c7 _[C,h,hb]=freecontourf2(x,y,z,cv,cmap,ifirst,ndelta,iswbg,bardir,tex);7 G7 h$ p2 a% Y# {* j
3 S+ g$ S7 m0 e/ n4 O0 F6 N
1 O4 N" b8 t; L! }& j; J
5 E: R# N# j1 Z
" {, ~: y* m& G
! i6 R/ R; S; p" M/ e9 h z: U
6 空间插值&白化
! r; s. ~; j8 h) W9 y1 [( d" [. N# i E
clc;clear;close all
, i: O0 A+ ~% S$ j6 _* R6 Eload('mdata/chnmon756.mat');( o( f1 F* {( H% h1 n( q5 f
idate=find(stat.date>=19881200&stat.date<=19981100);
/ t, Q2 }6 H( \' o( e) `/ A9 ux=stat.long;* G- z. ^. M' e B! _) ?) o. b) i
y=stat.lat;9 ?! Q+ ?2 A5 _
z=stat.prec(idate,:);; ~ X- s3 Q- w9 K! r& _
z=mean(z)';%mm/day
h, j1 X2 ?* ~. Nlo=[72:1:137];
8 a6 z( S7 k& h$ qla=[15:1:55];
4 o! `, L8 V( M[clo,cla]=chngon('g');
8 O$ d- {+ O+ m, |) C2 |[lo2 la2]=meshgrid(lo,la);
) [& }8 A( a7 Q, w' Oin=inpolygon(lo2,la2,clo,cla);2 R8 b/ k% w; O& b) Z. \7 ?
cv=[0.1 1:5];
. j* Z% [# j) \( B: L' ?# d2 X. U% cv=[0:5];
7 s n1 }/ S8 Z0 A6 }& w5 n% cmap=nclcmap(142,numel(cv)+1);
8 o, R* x. i2 @) K" c: N. ?load('colorbar-mat/rainbow.mat');# f- `8 F/ g$ J" @3 j: }6 X
cmap=rainbow;+ o/ j* B7 P4 p
zi=cus_griddata(x,y,z,lo,la,'v4');9 P, y2 `; T1 g D: r
figure% V ?- f' ]& e6 N" ]# g
hold on$ N+ P- q B* _3 ~2 I9 M
% [C,h,hb]=freecontourf(lo,la,zi,cv,cmap,true);
4 d" j- V c; [" C2 ?* ?- F[C,h,hb]=freecontourf(lo,la,zi,cv);% F. e0 x5 }: _/ b
set(h,'edgecolor','none')
& I. \4 |9 e" \" Xset(h,'linew',2)
! e7 e- Z: h$ Hchnmask2(lo,la,'g')
2 [: N3 {! ^" m( K0 ~; m7 jhc=mapnorm(lo([1 end]),la([1 end]),false,false,true,true,true,0,[10 5],1,'g',2);
3 H# ~( V1 i6 c W, igrid off
% ~! O& x# v2 Iset(gcf,'pos',[89 200 520 445])
2 j. i" z3 D( I. Z" A f9 qset(gca,'pos',[0.0913 0.1504 0.8747 0.7730]);* C1 H- m4 H0 }' O4 m
ssaxes(4,0.14,[3 4 1.6 1.1 1.35 0.98],'nanhai2',2);" R" H+ [' Q3 L! b( r" w
set(gca,'linew',2);$ U) _. n' N$ i1 a$ @, {4 {2 M( b
set(gca,'fontsize',14)7 Y- V' }* Y) m' \6 ?
* o F. L" {- [: D2 c P8 @; S
6 V# G, A& r. c1 Z* O/ L" U9 ?- M q% B
& ^+ ~: a* y8 s; P, Z+ ^- V
9 ~6 ~; R s( A% m3 @7 WRF模拟嵌套区域绘制, H- x4 o5 C6 Y
: T, p/ i3 n7 M: _: K; y
clc;clear;close all5 o& A0 b! m# ^% S2 K* J2 V1 Q
si=[1, 107, 94, 47];
p4 ^' G$ y: |& N& d- t! ^" Jsj=[1, 47, 37, 122];7 d& B+ m u% c: N5 T
nx=[179 169 151 145]; %nested grid number should be 3n+1
- l8 h( _3 X; E) H: t! m1 I$ bny=[161 199 157 151];
0 K0 r) S9 E7 Q H5 c B kdxy=[30000 10000 3333.33 3333.33];- D+ W0 p3 c9 h
grat=[1 1/3 1/3 1/3];" U; S' l' a6 y
pid=[1 1 2 2];
9 D( ^1 W; F+ }& A) A% param=[nx(1) ny(1) 100 35 30 60 36000];
5 u9 z! H1 @2 v" \: Q% X/ O: O1 N% param=[nx(1) ny(1) 105 35 (nx(1)+1)/2 (ny(1)+1)/2 30 60 115 dxy([1 1])];( F4 ` G6 g/ B0 v& E: K5 A. S
param=[nx(1) ny(1) 102 36.5 (nx(1)+1)/2 (ny(1)+1)/2 30 60 102 dxy([1 1])];: w" p/ X- A! `' _, ?
[x y]=wrf_nestxy(si,sj,nx,ny,grat,pid);$ r7 @3 v+ v6 ]( A# x5 y* d7 P
nb=10;
( j, Z0 K- R# k$ f/ I7 w! w% Unbb=nb*[1 1/3];
9 u* R- Y. k* @! w% q' t, {figure,hold on! J4 m$ o' O: R2 o9 Y
maplam(param,false,false,true,true,true,0,[10 5],3,'h',2,':');" X& Q; f) z% ~: s
for i=2:length(pid)+ k" E0 L5 n# C8 p K
[xx yy]=meshgrid(x{i},y{i});
9 Y$ r6 Y. D9 ?0 `( f E3 ^. S xx2=[xx(1,:) xx(:,end)' xx(end,end:-1:1) xx(end:-1:1,1)'];
: s9 s s H+ H: b% Z! h$ l yy2=[yy(1,:) yy(:,end)' yy(end,end:-1:1) yy(end:-1:1,1)'];2 s T% Z: \, U% O: [( b% w
plot(xx2,yy2,'m','linew',2)
' }9 r$ w9 Z3 Z" L% R6 \end
9 t; T% B% C# S0 g& @" i/ I[xx yy]=meshgrid(x{1},y{1});. @0 f7 x4 @0 z2 B+ M, m7 m
xx2=[xx(1,1)+nbb(1) xx(1,end)'-nbb(1) xx(1,end)-nbb(1) xx(1,1)+nbb(1) xx(1,1)+nbb(1)];
0 e/ f! J9 d4 G0 Z4 Lyy2=[yy(1,1)+nbb(1) yy(1,1)'+nbb(1) yy(end,1)-nbb(1) yy(end,1)-nbb(1) yy(1,1)+nbb(1)];
! s' {. |6 C- a8 Iplot(xx2,yy2,'b','linew',2)
0 v" t( V7 Y4 @, b. ^load prvpatch% u+ g4 i* e5 e' y* k$ ]: X& r
[clong clat]=polyjoin({s(1:34).long},{s(1:34).lat});3 {3 }2 I2 f# e/ j# I' y% I c0 J3 \
[cx cy]=deg2grd(clong,clat,param);
. c/ Y: s% u- \5 L4 c) Jplot(cx,cy,'k')
& o" t! J, b6 \: ?1 X5 ~0 F9 X8 V$ \8 V& `) e H+ p1 |
) ?7 t1 j8 O3 E, h9 a* y; U8 d! Y
; N' @" J. Y% [/ ]6 Z/ C( i, |
7 t$ d, Y3 v7 q$ H
/ i, A# b9 O6 n- B- U, I/ X
8 Analysis of power spectrum
+ M. [. i3 M. U8 X6 q) x, t1 P% J8 d% p) ?9 L; \
clc;clear;close all$ c, B+ T9 [4 `$ g( U# @
% Analysis of power spectrum" c8 E, w8 ]: N/ P/ ]% X
% load enso_sst.mat
- h# n' @3 U5 Zzsim=xlsread('data2.xlsx');1 E) |$ T# @7 e9 p7 ]) }2 n" b" {8 ?# A
zi=zsim(:,1);+ [( H3 C8 M' X1 w0 J0 b
zi=zi-mean(zi); % must remove mean.
* `8 p5 U3 o8 j1 e$ j%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
7 e; @& Q3 c3 ?* u%fft
6 z2 [( S0 F ?0 [Fs = 1; % Sampling frequency
. U/ R, r5 d) d5 ^& Y" Q' LT = 1/Fs; % Sample time, u1 F. ?5 `' ?. j/ N
L = length(zi); % Length of signal' r5 W$ G5 N( z4 v g% Y: f5 P
t = (0:L-1)*T; % Time vector, I/ s2 } }& \
y=zi;0 p4 R6 U2 p# i W$ e
figure,hold on6 j: c( h/ G" T8 L4 u2 ?
% NFFT = 2^nextpow2(L); % Next power of 2 from length of y4 q% m# u# v9 B1 S
NFFT = L; % Next power of 2 from length of y
0 ?2 @& C: }( D, o' [Y = fft(y,NFFT);
! [5 W/ }5 P# rP=Y.*conj(Y)/NFFT; %power spectrum density
/ r `/ y* Z: h5 J2 G. nP=smooth(P,7);- y' k. `0 v; _( u e5 y" t! Q3 D( ~& J4 ]
f=Fs/2*(0:NFFT/2-1)/(NFFT/2);' _( `6 q- G2 V! s* T0 Z
P=P(1:NFFT/2);
+ b' Z' f) }0 D/ c. Gdf=1/NFFT;* e4 {7 f: w8 W* C0 _5 t5 h, t
svar=(P(1)+P(end))*df/2+sum(P(2:end-1))*df;& F! s, X$ }9 M* u9 u
svar0=var(y);8 m1 d. n# r8 |6 @4 B7 H# B
P=P/svar*svar0;$ Y: n+ z ?3 f9 b. m( t- S
% Plot single-sided amplitude spectrum.
, U5 p! `' b$ V' E* `5 Y* |9 P4 i7 |2 Cplot(f,P,'r')* T0 T% [5 L+ ?& ^' O
title('Single-Sided Amplitude Spectrum of y(t)')2 v9 U3 e; t5 o* ]
xlabel('Frequency (cycles/year)')) }& H. i, }( I* z
ylabel('Variance')
5 H* y& d% ]0 f# T) B$ E% ~
+ l; H3 z! z; \$ w8 e
' s# T, |/ m! H) m" Z+ w' e
! u, p' b/ i! A) ^. f! G% M+ e) P% A
/ U5 \$ N0 o5 c* j0 a9 Taylor图
: e# B6 a2 B0 B4 z/ t' N# J5 _1 |9 D4 `, }" U
clc;clear;close all
! K9 i# l6 N+ mzsim=xlsread('data2.xlsx');
: x C+ i; H2 _1 E: r3 z0 B9 \% Example for ploting taylor diagram
3 O4 U6 F& K% @5 ]9 p. @lss={ 'o','v','s','^','p','o','v','s','^','p','o','v','s','^','p','o','v','s','^','p','o'};
6 \, }1 {# U; x, hlcc=[1.0000 0 0
/ o( g! f( L8 {, L' l% P 0 0.8000 0
. o/ ^0 P/ k/ @, I4 P 1.0000 0 0# b/ _7 p% w0 u
0 0.9000 0.9000& q) W7 N# Y" N. T- L
1.0000 0 1.0000
2 Z' L# Z, v4 B( R b1 D 1.0000 0.8000 0 f1 M' p4 x6 V" R/ H' P
1.0000 0 0
2 J# h7 `7 t+ l3 @7 l. T' ` 0 0.8000 02 a/ n: v* K5 T8 ], L
0 0 1.0000
9 @( A8 k3 n- p" D: j1 m 0 0.9000 0.9000
9 z- c2 ~& d6 r& Z2 E 1.0000 0 1.00009 S2 M* G! u0 H+ V
1.0000 0.8000 0
5 l* a0 J6 L4 U5 B4 s 0 0 1.0000) q- }" b1 ?6 d; c, [( A" N/ a ?
0 0.8000 0& g% C3 G+ G2 U# A
0 0 1.0000
$ d0 x4 j. L& `* }% r6 n 0 0.9000 0.9000
7 R1 }& J8 R6 t& P 1.0000 0 1.00004 ?) ], J' Q9 t/ Q1 V
1.0000 0.8000 0" e) C; ?% k! ^5 ? v
1.0000 0 0: k: W; U( s; h+ L
0 0.8000 0
1 q/ j% \8 i# W8 p5 y& s, p 0 0 1.0000];
! g w; V2 R' [7 t( l* nzobs=zsim(:,1);, g0 E: x9 C& F4 G
zsim=zsim(:,1:end);+ Y: m$ X% L1 A* p5 Q) a/ t
stag=cellstr(num2str((1:size(zsim,2))'));3 {' ^% ?, x2 m) Q* z, a e
stdd=std(zsim)/std(zobs);, v% o9 n& G( A+ R3 f$ h
ccorr=corr(zobs,zsim);
3 B; Z1 v* R- H- Az1=zobs-mean(zobs);' n1 s2 R8 l% k" J. J
z2=zsim-mean(zsim);
! |# e& A6 i- r/ [. E, Ormse=rms(z2-z1)/std(zobs);1 E+ \8 i' [$ j* f2 I
rmse2=sqrt(stdd.*stdd-2*stdd.*ccorr+1);
$ c" q1 r g; G0 \% a9 P2 h' x[hp,hp_std,hp_rmse,ht_corr,ht_rmse,hl]=TaylorDiag(zobs,zsim,lcc,lss,stag);
) k. i6 s; q& s8 ^" k* hset(hp,'markersize',8);% _& R) X6 m- {2 f
set(ht_rmse,'color','k');* k3 X& K5 L+ x) \3 w' y
, I1 n6 y/ [) Q8 J9 K {
; n `2 \; v" j9 V
5 y9 `; `9 g* s9 o1 T1 g; S9 p
# ]6 H% E7 |; |$ C1 A( F |
|