matlab如何让plot更平滑,如何在MATLAB中平滑繪圖?

本文介绍了在MATLAB中使plot更平滑的几种方法,包括加权平均、使用smooth函数、Savitzky-Golay过滤以及移动平均。讨论了如何选择合适的平滑程度,以及针对异常值的处理建议。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

I have some 9000 points that are plotted on a graph:

我在圖上畫了9000點

(完整的決議)

78018f6ea5cd7ee5803b93fad89e9ee6.jpe

Actually, the plot is not as smooth as I wanted it to be. Is there some way I can smoothen the graph to a required degree?

實際上,情節並不像我想象的那么順利。有沒有什么方法可以讓圖形達到要求的程度?

Or some form of thresholding so that I can selectively smoothen out the parts that is too bumpy?

或者某種形式的閾值,這樣我可以有選擇地撫平那些太顛簸的部分?

I am not sure but can fast-fourier-transform help?

我不確定,但是快速傅里葉變換能有幫助嗎?

5 个解决方案

#1

17

A simple (ad hoc) way is to just take a weighted average (tunable by alpha) at each point with its neighbors:

一個簡單(特別)的方法是,在每個點與它的左鄰右取一個加權平均(可調):

data(2:n-1) = alpha*data(2:n-1) + (1-alpha)*0.5*(da

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值