From 12:00 PM - 4:00 PM CST on Thursday, October 18, ni.com will be undergoing system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Table Of Contents

Array Subset (Clock-Driven Logic)

Last Modified: September 13, 2017

Returns a portion of an array starting at a specified index and containing a specified number of elements.

connector_pane_image
datatype_icon

array

An n-dimensional array of any type.

datatype_icon

index

First element, row, column, or page to include in the portion of array you want to return.

If index is less than 0, the node treats it as 0. If index is greater than or equal to the array size, the node returns an empty array.

Relationship between index Inputs and array Dimensions

For multidimensional arrays, index inputs correspond to row-major order. Thus, the first index corresponds last dimension of the array input, and the last index corresponds to the first dimension of the array input. The following table shows the relationship between four index inputs and the dimensions of a 4D array input.

index Order Corresponding Dimension in array Input index Name
1 4th volume index
2 3rd page index
3 2nd row index
4 1st column index
datatype_icon

length

The number of elements, rows, columns, or pages to include in the portion of array you want to return.

If index plus length is larger than the size of the array, the node returns only as much data as is available.

Default: The length from index to the end of array.

datatype_icon

subarray

The portion of array starting at index and containing length elements.

Where This Node Can Run:

Desktop OS: none

FPGA: All devices

Web Server: Not supported in VIs that run in a web application


Recently Viewed Topics