MATLAB: Finding maximum and minimum values

value. maximum. minimum. excel

Hello I wish to find the maximum and minimum values for a tidal data.
I want to find the maximum and minimum values for each tidal cycles.
I use matlab to read these values from a excel file, As shown from picture above,
I want to find the maximum value for two peaks, and two bottoms along with the location of the values.
Any suggestions? Many Thanks

Best Answer

Read about findpeaks ..also you can use max min .