yu = smoothdata(y + 1, 'movmean', 30); %需要删除inf yu(yu == inf) = NaN; yu = fillmissing(yu,'previous'); 填充缺失值 - MATLAB fillmissing- MathWorks 中国