LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to find global max and min?

I have a series of data which look like the picture below.

I want to be able to find out the global maximum point and minimum point, ignoring all the local max/min. I know roughly:

- the period of the signals (i.e the horizontal distance between the two global peak, or the hor distance between the two global min)

- the vertical distance between two max and min.

 

I want to be able to pick out the outlier - in this case, it is the global peak circle in blue. Bearing in mind that local max or local min should be ignored.

Can anyone help me with the algorithm? Or LabVIEW already has something out of the box?

 

Global_max_min.PNG

0 Kudos
Message 1 of 7
(3,734 Views)

This post should help you at least get started.

 

Use the example finder and search for 'peaks', there's some decent examples in there.

--
Tim Elsey
Certified LabVIEW Architect
0 Kudos
Message 2 of 7
(3,730 Views)

Whatever you are showing marked as blue is not a global maximum or minimum by and reasonable definition. (as opposed to the local maxima, the global maximum is typically the highest point overall, which would be easy to find).

Near the blue point you seem to have a phase shift in the data, nothing else, and the amplitude of that blue peak could be quite random.

 

What are you actually looking for?

 

 

Message 3 of 7
(3,709 Views)

@altenbach wrote:

Whatever you are showing marked as blue is not a global maximum or minimum by and reasonable definition. (as opposed to the local maxima, the global maximum is typically the highest point overall, which would be easy to find).

Near the blue point you seem to have a phase shift in the data, nothing else, and the amplitude of that blue peak could be quite random.

 

What are you actually looking for?


Allow me to put words in his mouth, which may or may not be accurate.  You're of course right about the global max definition, but I think what he means is 'global max per spike'.  You'll notice some of the peaks have two local maxima on them. 

 

My understanding is that he wants to be able to pick out the 'global max' that is significantly different than the rest. (The one circled in blue)

--
Tim Elsey
Certified LabVIEW Architect
0 Kudos
Message 4 of 7
(3,696 Views)

The graph is the result of summing the intensity of a black-white strip in the vertical direction, within the red box.

The pitch of the strip is more or less a known value. The task here is to find out overlapping dark lines, or white gap which is wider than it should be.

That's why I need to be able to find out that outlier peak, based on the graph 

Overlapping_lines.PNG

0 Kudos
Message 5 of 7
(3,663 Views)

As I said, the "gap" is a discontinuity in phase and that's what you should look out for. Just because (in some situations) there is a small peak should be irrelevant for the detection of the discontinuity. You still haven't attached any typical data.

0 Kudos
Message 6 of 7
(3,659 Views)

Hi altenbach,

Here is the data and strip

overlapping_lines.JPG

 

 

0 Kudos
Message 7 of 7
(3,625 Views)