Smooth bad data in MattLab

1 回表示 (過去 30 日間)
Connor Burchell
Connor Burchell 2020 年 2 月 24 日
コメント済み: Alex Mcaulley 2020 年 2 月 24 日
I have some Velocity/Elevation data taken in a flume channel using an ADV probe. The majority of the data is good however, at certain elevations the data is erratic and the mean data plotted shifts quite considerably. (See below for an attached image). I am hoping to smooth this data out and generate a nice curve. Any suggestions?
  2 件のコメント
Alex Mcaulley
Alex Mcaulley 2020 年 2 月 24 日
You can try with smooth or medfilt1
Star Strider
Star Strider 2020 年 2 月 24 日
The smoothdata function is another option.

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

採用された回答

ME
ME 2020 年 2 月 24 日
I think you could easily do this by using find to locate the indices of all values lying in the shifted range. This would be something like:
idx = find(y>= 80 & y<=100)
but with the limits tweaked appropriately to set the exact range to be adjusted.
You can then use these indices to alter the relevant portion of the x data using something along the lines of:
X(idx) = X(idx) + 0.1
or whatever the appropriate value to shift is.
I'm sure there is much fancier and more automated ways of doing this but as a first approximation this should do a pretty good job.
  3 件のコメント
ME
ME 2020 年 2 月 24 日
I never said this was a fancy answer or even necessarily a good one! But it would give a quick way to get what was asked for. If you are going to be negative about peoples answers then how about trying to give some constructive feedback on how it could be improved or an alternative approach? Lets try to make this a positive place and cut out all of the negativity.
Alex Mcaulley
Alex Mcaulley 2020 年 2 月 24 日
I'm sorry, it wasn't my intention, your answer just surprised me and sometimes the simplest answer is the most useful

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

その他の回答 (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