Skip to content

Commit

Permalink
fix nc2struct for wrfinput_d01; comments
Browse files Browse the repository at this point in the history
  • Loading branch information
janmandel committed Jul 25, 2010
1 parent 9ecc25a commit bee953f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 1 addition & 3 deletions other/Matlab/netcdf/nc2struct.m
Expand Up @@ -32,12 +32,10 @@
switch ndims(v.var_value)
case 2
p.(lower(varname))=v.var_value(:,times);
case 3
p.(lower(varname))=v.var_value(:,:,times);
case 4
p.(lower(varname))=v.var_value(:,:,:,times);
otherwise
warning('argument times supported only for 2d to 4d arrays')
warning('argument times supported only for 2d and 4d arrays')
p.(lower(varname))=v.var_value;
end % case
else
Expand Down
6 changes: 5 additions & 1 deletion other/Matlab/vis3d/vprofile.m
Expand Up @@ -5,7 +5,11 @@ function vprofile(filename,x1,x2,tstep)
% filename string, WRF file name
% x1 distance in m from lower left end of domain in coordinate 1
% x2 distance in m from lower left end of domain in coordinate 2
% tstep the index in input files to compute this at
% tstep the index in input files to compute this at, or empty
%
% examples:
% vprofile('wrfinput_d01',100,100,[])
% vprofile('wrfout_d01_0001-01-01_00:00:00',100,100,1)

% the data for this time step
p=wrfatm2struct(filename,tstep);
Expand Down

0 comments on commit bee953f

Please sign in to comment.