read a periodic image(signal) and detect every wave then display every wave on separte figure help me please

read a periodic iamge and detect every wave then display every wave on separte figure
help me please

4 Kommentare

Could you be more especific with your question? It is not very clear. COuld you upload your image?
i want to part this periodic signal
every wave/step in separate figure
Do you want to crop out each peak/hump and display it in its own plot? Or do you want to take the Fourier transform and display each harmonic?
i want to crop out each peak/hump and display it in its own plot

Melden Sie sich an, um zu kommentieren.

Antworten (2)

If you have the Signal Processing Toolbox, invert the curve and find the peaks. These are really the valleys. Then crop them out and use plot().

12 Kommentare

i want functions (code) that do that and i dont know if i have Signal Processing Toolbox
Type ver to see if you have it. Othwerwise use this: http://www.mathworks.com/matlabcentral/fileexchange/25500-peakfinder
Then if your valley locations are in an array called valleyLocations, which are indexes, then
for index = 1 : length(valleyLocations) - 1
indexStart = valleyLocation(index);
indexEnd = valleyLocation(index + 1);
extractedSegment = yoursignal(indexStart : indexEnd);
subplot(4,4,index);
plot(extractedSegment, 'b-');
grid on;
end
im so sorry but i watched this page many times ago but no thing new i made alitte code for small task i have atrouble with this part of code can you write to me afull code that i put in matlab and working
x and y for what
lisen to me this is th image
i want to extract this periodic signal from the background and then part this periodic signal and plot every single signal in figure like this
of course without this background
Are you saying that you're dealing with an image of a graph (like one you scanned in from a flatbed scanner or plucked off the web somewhere) and don't have the actual x and y data that went into creating the graph?
no i dont have x,y i dealing with any image (contain signal periodic) to part their signal into aseparate figure) not just this image
You're going to have to turn it into x,y data by taking the image and finding what pixels the red curve shows up on.
how ?? i dont know how ?? listen to me there is two thinggs i dont know it (i wanted) how to extract this signal from back ground and how parted it into a separate signal
There is a File Exchange routine to read images and interpret them as graphs that the data can be extracted from.
can you help me I lost hope just i want a code or a function that do that ??
The submission Walter is referring to is http://www.mathworks.com/matlabcentral/fileexchange/36904-matlab-script-for-digitizing-a-published-graph but it looks like ahmed is done with us because he's started all over again with a brand new discussion on the very same question.

Melden Sie sich an, um zu kommentieren.

If you really are reading from an image, use the mentioned contribution to analyze the image to get the data.
Once you have data, you can go the theoretic route by performing an autocorrelation. See http://www.mathworks.com/help/econ/autocorrelation-and-partial-autocorrelation.html and also xcorr().
Alternately you can use one of the peak-finding routines, possibly one from the MATLAB File Exchange. Look for the maximum absolute value of peak anywhere in the data, and then look for additional peaks that are "quite close" in magnitude (including being on the same side of 0)
As a first approximation the cycle length is equal to the distance between maximal peaks. Now break up the data into groups of that cycle length.
That first approximation algorithm will be wrong when a single cycle contains several maximal peaks, such as if the graph looked like
_^_^___^_^___^_^__
Working out how to deal with such cases is left as an exercise to the reader.

Tags

Noch keine Tags eingegeben.

Gefragt:

am 16 Dez. 2013

Beantwortet:

am 20 Dez. 2013

Community Treasure Hunt

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

Start Hunting!

Translated by