Best curve smoothing approach to avoid strange artifact? [Screenshots Included]

2 ビュー (過去 30 日間)
Elijah Rockers
Elijah Rockers 2015 年 9 月 24 日
編集済み: Elijah Rockers 2015 年 9 月 28 日
I have some noisy, time-series data. Additionally, the data was collected in three consecutive sessions, with short breaks in between. Unfortunately the break times were not accurately recorded. I have done my best to estimate the length of the time breaks, and inserted them into the data, to get a closer representation of what the experiment actually observed.
I have tried a couple of different approaches to smooth the data, but I believe the breaks are causing strange artifacts in the data when smoothed. I am wondering what the best approach is to smooth my curves. Perhaps my break estimations need to be closer to the real values?
I tried polyfit, but it was just too inaccurate. I also used a window in the frequency domain to cut off high frequencies. I've attached a plot of the original data, and also my most recent attempt at smoothing, which was a smoothing filter followed by the smoothLine function from the file exchange.
Notice the large 'hump' at around 5000 seconds. This seems to be a constant problem I get whenever I attempt to smooth the data. The other graph is the raw data, with the breaks inserted.

採用された回答

Image Analyst
Image Analyst 2015 年 9 月 25 日
Why don't you try a Savitzky-Golay filter, done by sgolayfilt() if you have the Signal Processing Toolbox?
  2 件のコメント
Image Analyst
Image Analyst 2015 年 9 月 25 日
If you attach your data in a .mat file, I can try smoothing it.
Elijah Rockers
Elijah Rockers 2015 年 9 月 28 日
編集済み: Elijah Rockers 2015 年 9 月 28 日
sgolayfilt() kinda worked, but I had to smooth each of the three hours separately. Thanks!

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeSmoothing and Denoising についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by