![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/417848/image.png)
How can I get a smoothing line like Excel?
조회 수: 3 (최근 30일)
이전 댓글 표시
Dear all,
I got some test data sets and ploted them in excel, the following image is the result.
Left : no smoothing, just connecting each data with direct lines.
Right : connecting each data with default Excel smoothing method.
Excel smoothing method works well.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/417813/image.png)
But I tried some Matlab methods such as interp1, it seemed that they cannot work normally in my data sets.
In my opinion, the reason is that both x value and y value are not monotonous.
So are there any methods provided by Matlab library that can solve this problem?
Or any advice about what method Excel is using to plot a smoothing curve.
Best regards,
Sam
댓글 수: 0
채택된 답변
Nora Khaled
2020년 11월 18일
I tried the answer to this question
with your data
x = [-1 -.6 0 .6 1 .6 0 -.6];
y = [-0 .6 1 .6 0 -.6 -1 -.6];
I think it works...
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/417848/image.png)
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Preprocessing Data에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!