Jim Bickford wrote:
>
> Hello,
> I'm looking for a VI that will search through a 2-D array and search for
> primary and secondary peaks. Labview seems to have a VI to do this in 1-D but I have
> a function z=f(x,y). I want to find the 2 indices for the secondary peaks (a
> distinct peak but not necessarily the largest). If the program fit a gaussian or
> similar to determine sub-index accuracy that would be even better. If there are no
> VIs that are currently written for this, what do you think the best method would be
> to write it? (My array size is 1000x1000.)
>
> Many thanks in advance...
>
> Jim
>
> *****************************************************************************
> * Jim Bickford Tufts University * So many worlds, so
much to do. *
> * http://www.tufts.edu/~jbickfor * So little done, such things to be. *
> * jbickfor@emerald.tufts.edu * - Alfred, Lord Tennyson *
> *****************************************************************************
Jim,
you could use the 'array max & min' vi. Once you have the max, you could
replace that entry with 0 (save the original entry) and search for the
next max. When you're done, restore the 0 entry to the original value.
Walter