To download NI software, including the products shown below, visit ni.com/downloads.
Overview
This example removes a user specified value from an input array.
Description
This code uses array size and other array vi to complete this function. The output array is shortened by the number of elements removed
Requirements
Steps to Implement or Execute Code
Additional Information or References
VI Block Diagram
**This document has been updated to meet the current required format for the NI Code Exchange.**
Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.
You can find this and several other nice functions in the OpenG toolkit. The key when doing this is to not use the delete primitive repeatedly as it causes costly memory reallocations. Try to feed a large array with lots of removable items into the function and you'll se that it takes a lot of time. This VI does the job without the repeated delete operations (and is even quicker than the OpenG function as it does not bother to output the indices of the removed elements).