How to detect variations in data?

21 ビュー (過去 30 日間)
Mohamed Nedal
Mohamed Nedal 2019 年 12 月 23 日
コメント済み: Mohamed Nedal 2019 年 12 月 26 日
Hello everyone,
I would like to determine the location at which there is data variation (like the highlighted points in the attached image).
Kindly find the attached code + .mat file.
Each sub-plot represents a variable on y-axis and the time on x-axis. Usually, the variation appear in several variables (plots) like this one.
data .jpg
Could you suggest the best method to do so?
and How can I determine the starting and ending points of that variation?
I appreciate your help.

採用された回答

Image Analyst
Image Analyst 2019 年 12 月 24 日
You might try movstd() to do a sliding window standard deviation. Then threshold it to find elements where the standard deviation is what you deem "high". See attached code where I did it for your "B" signal. Adapt it to do any other signals you want.
0000 Screenshot.png
  1 件のコメント
Mohamed Nedal
Mohamed Nedal 2019 年 12 月 25 日
Thank you very much!

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

その他の回答 (1 件)

Ridwan Alam
Ridwan Alam 2019 年 12 月 23 日
Depends on how complex of a solution you are looking for. There are algorithms for change point detection that you can try.
Or, you can have a sliding window (your defined size) over the signal and look for specific features (e.g mean crossing rate, variance, etc. depending your signal type) to find the windows that contain a "change".
Hope this helps.
  9 件のコメント
Image Analyst
Image Analyst 2019 年 12 月 26 日
I think findchangepts() locates points where the data goes from smooth to something drastically different, or vice versa. So it basically finds corners or elbows in the data.
movstd() on the other hand gives a high signal wherever the data has high variability regardless if the signal looks like a corner or elbow there.
Mohamed Nedal
Mohamed Nedal 2019 年 12 月 26 日
Okay, thanks a lot.

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

カテゴリ

Help Center および File ExchangeMatrices and Arrays についてさらに検索

製品


リリース

R2017b

Community Treasure Hunt

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

Start Hunting!

Translated by