www.gusucode.com > matlab 案例源码 matlab代码程序 > matlab/StandardDeviationExcludingNaNExample.m
%% Standard Deviation Excluding |NaN| % Create a vector and compute its standard deviation, excluding |NaN| values. % Copyright 2015 The MathWorks, Inc. A = [1.77 -0.005 3.98 -2.95 NaN 0.34 NaN 0.19]; S = std(A,'omitnan')