Changeset 21240
- Timestamp:
- 09/30/16 15:20:17 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/m/plot/plot_gridded.m
r20670 r21240 92 92 options=addfielddefault(options,'axis','xy equal'); % default axis 93 93 applyoptions(md,data,options); 94 95 function y = nmedian(x,n) 96 %NMEDIAN Generalized median filter 97 % NMEDIAN(X,N) sorts elemets of X and returns N-th value (N normalized). 98 % So: 99 % N = 0 is minimum value 100 % N = 0.5 is median value 101 % N = 1 is maximum value 102 103 if nargin < 2 104 n = 0.5; 105 end 106 y = sort(x(:)); 107 y = interp1(sort(y),n*(length(y)-1) + 1);
Note:
See TracChangeset
for help on using the changeset viewer.