Pat,

you asked on Tue, 20 Jan 2004 14:11:56 -0500:
> Analyzing an array of 600 acquired points over 3 milli-seconds
> post-process; we would like to capture the values that cross a set (Y)
> threshold and then save them to a separate array along with their (X)
> value.
> 
> (Y) representing the value of the threshold and (X) representing the
> "point" (0-600) that hit the threshold.

Just some ideas:
I'd start with a step that searches your data for any continuous blocks
'above the threshold'. Afterwards you could copy any of the found blocks
ouit of the original data. This leaves memory allocation at an minimum.

The first step can be done in a FOR loop with some shift registers. One
could hold an arry of (cluster of (startIdx, endIdx)) (initialezed with an
empty array), another one a boolean 'above?' (initialized with False).
Check for every data point if it is above and if 'above?' changed from the
last iteration. If so, set the apropriate Idx in the last array element
and, if 'above?' switched to True, append a new array element before. 

When your FOR finishes you may just feed that array with autoindexing into
another For and feed the original data without autoindexing. Now you can
catch any subarrays starting at startIdx with a length of
(endIdx-startIdx). 
I did not really get your display reqs, so you have to deside if and how
you append those data for displaying purposes.

Just my �0.02!
Greetings from Germany!
-- 
Uwe Frenz


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Dr. Uwe Frenz
Entwicklung
getemed Medizin- und Informationtechnik AG
Oderstr. 59
D-14513 Teltow

Tel.  +49 3328 39 42 0
Fax   +49 3328 39 42 99
[EMAIL PROTECTED]
WWW.Getemed.de


Reply via email to