Converts a 3-columns representation (i.e. X, Y, and Z) into a two-dimensional table.

## Syntax

**NxFold**(

**X**,

**Y**,

**Z**,

**X-Levels**,

**Y-Levels, KeepNA**)

**X** is a range of cells (one dimensional array) of the 1st variable (X) - independent.

**Y** is a range of cells (one dimensional array) of the 2nd variable (Y) - independent.

**Z** is a range of cells (one dimensional array) of the 3nd variable (Z) - dependent.

**X-Levels** is a one dimensional array of cells (e.g. rows or columns) for corresponding desired output levels/values of X (1st variable) in the data table. If missing or omitted, all levels found in X are assumed.

**Y-Levels** is a one dimensional array of cells (e.g. rows or columns) for corresponding desired output levels/values of Y (1st variable) in the data table. If missing or omitted, all levels found in X are assumed.

**KeepNA** is a flag for leaving (or purging) observations with missing values (e.g. blank, #N/A, #VALUE!, #NUM!, empty cell) found in the input data set. If missing or omitted, keepNA is assumned False.

## Remarks

- The NxFold function must be entered as an array formula in a two-dimensional cells range that has the same number of rows as X-levels, and number of columns equals to number of Y-Levels.
- Use NxFold to transform the representation or the format of 3-D data set (X,Y,Z) into a tabular form suitable for data visulaization (i.e. plotting) and/or interpolation.
- The observations in X,Y and Z can have any order, and are not assumed to be sorted.
- The X and/or Y arrays may have missing values (#N/A). In this case, NxINTRPL will remove those entries.
- The Z arrays may have missing values (#N/A). NxFold keep/remove those entries based on "KeepNA" flag setting, only if corresponding X and Y values are given (i.e. not missing).
- The X-Levels and Y-Levels may have missing values (#N/A), In this case, NxFold will remove those entries.
- The X-Levels and Y-Levels can have any order, no sorting is required.
- The values in X-Levels must be unique, duplicate values, if found, are removed.
- The values in Y-Levels must be unique, duplicate values, if found, are removed.
- The NxFold() function is available starting with version 1.66 PARSON.

## Files Examples

## References

- John Walkenbach (2002).
*Excel charts*. Wiley. ISBN 978-0764517648.

## Comments

Please sign in to leave a comment.