LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Find threshold in every matrix row, and some the following elements.

Hello,

after an acquisition I have a 3D array whose dimensions are 1x400x10000, in fact it's a 2D array, but labview sees it as a 3D array.

I need to find the threshold in every row, and sum 1000 elements, after the threshold element, in order to get a 1D array of 400 element.

(I'm using labview 8.2, in case someone can attach some example).

Thank you!

0 Kudos
Message 1 of 6
(2,360 Views)

What have you tried?  You will learn more about LV if you try it and ask for help on specific questions.

 

Hint: Index array is your friend.

 

Lynn

0 Kudos
Message 2 of 6
(2,348 Views)

This is what I tried up to now:

I wanted to see if in this way I could get an array with the threshold elements.test.JPG

0 Kudos
Message 3 of 6
(2,344 Views)

@danieleviola wrote:

Hello,

after an acquisition I have a 3D array whose dimensions are 1x400x10000, in fact it's a 2D array, but labview sees it as a 3D array.

I need to find the threshold in every row, and sum 1000 elements, after the threshold element, in order to get a 1D array of 400 element.

(I'm using labview 8.2, in case someone can attach some example).

Thank you!


A 1 x 400 x10000 array is a 3D array.  It just so happens that the one particular dimension is only 1 element long.  As Lynn hinted, if you want to turn it into a 2-D array, then you need to use Index Array.

0 Kudos
Message 4 of 6
(2,340 Views)

OK, now I achieved in having an array with the position of the slope of the acquisition matrix,

next step will be summing the elements of that matrix starting from the slope point.

test.JPG

0 Kudos
Message 5 of 6
(2,328 Views)

What is going on in your True case statement?  That looks like a Rube Goldberg to me.

 

Building a 1-D array into a 2-D, then indexing out the 1st (#0) row leaves you with the same thing you started with.

0 Kudos
Message 6 of 6
(2,318 Views)