data extraction method related question
Show older comments
one of my dataset shows as below figure. I want to corp proper range of windows which could represent each spikes or peaks - thus pulsed signals. I want to extract a peak into a window.
Note that alarm rings when signal touches '0.5'

But signals do not show regular behaviour. I don't quite sure how I can catch both start and end point of the signal. Although I tried to use moving average to get some idea from slope, it doesn't quite acurate. for instance, slow gradient changes are not detected.
below case is easy to catch,

but this one is tricky. one spike occurs and then another one appears.

Another exmaple, as you could recognised from below figure, signals are already touches 0.5 line(alaram level). But there's no alarm event in real field - thus, this case, detector shows malfuction.

My job is find out why. Back to the begining, I need to collect all signals from every sensor dataset. I will then cluster them into proper groups.
To do this, cropping every alarm events from dataset is the first step to me. I am almost newbie handling dataset in Matlab.
2 Comments
Jan
on 19 Dec 2018
It is not implicitly clear, what you consider as "spike" or "peak". You have to define this accurately at first with exact mathematical expressions. I cannot know what "that alarm rings when signal touches '0.5' " means.
What exactly is your Matlab related question?
Jack Ahn
on 20 Dec 2018
Answers (1)
Image Analyst
on 20 Dec 2018
Is this what you mean
threshold = 0.5;
aboveThreshold = signal >= threshold;
maskedSignal = signal; % Create copy/initialize
maskedSignal(~aboveThreshold) = 0; % Zero out where it's below threshold.
% Plot only those elements above the threshold
plot(maskedSignal, 'b-');
grid on;
3 Comments
Image Analyst
on 20 Dec 2018
Edited: Image Analyst
on 20 Dec 2018
Attach your actual data with the paper clip icon so we can try some things with it.
And exactly how is the full window determined? It's not the width of the peak until it first touches zero (like at 1.18) because you're going out past that (like to 1.23).
Have you tried the findchangepts() function?
Jack Ahn
on 20 Dec 2018
Categories
Find more on Descriptive Statistics in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!



