필터 지우기
필터 지우기

Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

How do I use the command 'smooth' to smooth a plot of data I have pulled from two matrices?

조회 수: 1 (최근 30일)
Here is the code I used:
if true
cloudy = find(Tday > 312.38 & Tday < 312.91);
T1smooth = smooth(Tmatrix(cloudy),'lowess');
figure(3),plot(Tday,T1smooth)
end

답변 (1개)

OCDER
OCDER 2018년 5월 22일
편집: OCDER 2018년 5월 22일
Assuming Tmatrix is a 1xN or Mx1 matrix, your use of smooth is correct. But note that you are doing smoothing ONLY on cloudy days, and not all days. The other way to do this is smooth Tmatrix, and then take the cloudy days. You'll probably get different results, but which is the correct order depends on the application.
plot(Tday(cloudy), T1smooth)

이 질문은 마감되었습니다.

Community Treasure Hunt

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

Start Hunting!

Translated by