📄 map2mat.m
字号:
% D = MAP2MAT(F,C) Reshaping matrix%% => Conversion of a 'map' matrix C(TIME,LON,LAT) into a D(TIME,PT) matrix% under the mask F(LON,LAT).% F is a matrix contenaing 1 where you would like to keep the point and% 0 elsewhere.%% Rq: No check is done about the input.%% See also: mat2map%================================================================% March 2004% gmaze@univ-brest.frfunction [D] = map2mat(F,C);% Get dimensions[tps nolon nolat] = size(C);% So output matrix will be:D = zeros(tps,nolon*nolat);% point indiceipt = 0;% 'Un-mapping' :for iy=1:nolat for ix=1:nolon if F(ix,iy)>0 ipt = ipt + 1; D(:,ipt)=squeeze(C(:,ix,iy)); end % if end % forend %for% OUTPUT:D = squeeze(D(:,1:ipt));
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -