Last Modified: August 13, 2019

Performs two-dimensional interpolation on gridded points by using the nearest interpolation method.

Tabulated values of the dependent variable.

Tabulated values of the independent variable in the *x* domain.

This input accepts a 1D or 2D array of double-precision, floating-point numbers.

All interpolation methods require that **x** be monotonic along each row, and all rows must be identical. Otherwise, this node uses only the first row of **x** to perform the interpolation. If **x** is not empty, the number of columns in **x** must equal the number of columns in **z**. If **x** is empty, this node treats **x** as an array whose size equals the size of **z** and whose rows are [0, 1, …, *N* - 1], where *N* is the number of columns in **z**.

Tabulated values of the independent variable in the *y* domain.

This input accepts a 1D or 2D array of double-precision, floating-point numbers.

All interpolation methods require that **y** be monotonic along each column, and all columns must be identical. Otherwise, this node uses only the first column of **y** to perform the interpolation. If **y** is not empty, the number of rows in **y** must equal the number of rows in **z**. If **y** is empty, this node treats **y** as an array whose size equals the size of **z** and whose columns are [0, 1, …, *M* - 1]^{T} , where *M* is the number of rows in **z**.

Number of times that this node interpolates values repeatedly and evenly between each **x** and **y** element to generate **xi used** and **yi used**.

**ntimes** determines the locations of the interpolation values. If you wire data to **xi** or **yi**, this node ignores **ntimes**.

**Default: **1

Error conditions that occur before this node runs.

The node responds to this input according to standard error behavior.

Standard Error Behavior

Many nodes provide an **error in** input and an **error out** output so that the node can respond to and communicate errors that occur while code is running. The value of **error in** specifies whether an error occurred before the node runs. Most nodes respond to values of **error in** in a standard, predictable way.

**Default: **No error

Values of the independent variable in the *x* domain where interpolated values of the dependent variable are to be computed.

This input accepts a 1D or 2D array of double-precision, floating-point numbers.

**xi** and **yi** must be the same size.

Values of the independent variable in the *y* domain where interpolated values of the dependent variable are to be computed.

This input accepts a 1D or 2D array of double-precision, floating-point numbers.

**xi** and **yi** must be the same size.

Interpolated values of the new points that correspond to the independent variable values.

Values of the first independent variable at which interpolated values of the dependent variable are computed.

If you wire data to **xi**, **xi used** returns **xi** unchanged. Otherwise, **xi used** returns an array with identical rows of 2^{ntimes} - 1 points located evenly between each two adjacent elements in the first row of **x**, and the number of rows in **xi used** equals the number of rows in **yi used**.

Values of the second independent variable at which interpolated values of the dependent variable are computed.

If you wire data to **yi**, **yi used** returns **yi** unchanged. Otherwise, **yi used** returns an array with identical columns of 2^{ntimes} - 1 points located evenly between each two adjacent elements in the first column of **y**, and the number of columns in **yi used** equals the number of columns in **xi used**.

Error information.

The node produces this output according to standard error behavior.

Standard Error Behavior

**error in** input and an **error out** output so that the node can respond to and communicate errors that occur while code is running. The value of **error in** specifies whether an error occurred before the node runs. Most nodes respond to values of **error in** in a standard, predictable way.

The nearest interpolation method selects the **z** value that corresponds to the (**x**, **y**) value that is nearest to the current (**xi**, **yi**) value. The interpolated value is set to the nearest data point.

With the nearest interpolation method, this node finds the point nearest to (**xi**_{m, n}, **yi**_{m, n}) and commits the corresponding z value in **z** to **zi**_{m, n}. In the following figure, **zi**_{m, n} = *z*_{i, j + 1}.

**Where This Node Can Run: **

Desktop OS: Windows

FPGA: Not supported

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