Fill outliers without a loop for each rows

조회 수: 2 (최근 30일)
Ahmet Hakan UYANIK
Ahmet Hakan UYANIK 2022년 10월 20일
답변: David Hill 2022년 10월 20일
Hello everybody,
I have a matrix e.g 45500x24, and for each row, I would like to check the outliers and fill with the nearest non-outlier value.
Normally I have been doing,
for i=1:length(matrix)
matrix(i,:) = filloutliers(matrix(i,:),"nearest","median")
end
Not sure if it is the correct way but it surely takes so much time. Do you have any optimal way?

채택된 답변

David Hill
David Hill 2022년 10월 20일
Try this:
matrix= filloutliers(matrix,'nearest','median',2);

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Curve Fitting Toolbox에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by