Example Code

Separating Array Elements into Positive and Negative Values

Code and Documents

Attachment

This VI takes an input array that contains a mixture of positive and negative values and separates that array into two smaller arrays: one that contains the negative values and one that contains the positive values.

The Initialize Array function and Build Array function are used and the For Loop sets its count by auto-indexing the input array.

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.

Contributors