HSTACK

Formulas / HSTACK
Combine arrays horizontally into a single array.
`HSTACK(array1[,array2,...])`
• array1 - required, the first array or range to combine
• array2 - [OPTIONAL] the second array or range to combine

Examples

• `=HSTACK({1,2,3},{4,5,6})`

The HSTACK function can be used to combine two arrays of data. For example, this formula will combine the array constants 1, 2, 3 with the array constant 4, 5, 6 and return the result 1,2,3,4,5,6.

• `=HSTACK(B2:B4,D2:D4)`

The HSTACK function can also be used to combine two ranges of cells, and will combine the range B2:B4 with the range D2:D4.

• `=HSTACK(A2:A4,C2:C4)`

The HSTACK function can be used to combine two columns of data, and will combine the range A2:A4 with the range C2:C4.

Summary

The HSTACK function is used to combine multiple arrays horizontally into one larger array. It appends each of the arguments to the array to create the larger array.

• The HSTACK function combines ranges on a worksheet or in-memory arrays created by a formula into a single array and provides fully dynamic output, automatically updating when any data changes.
• The HSTACK function is an efficient way to combine multiple arrays horizontally into a single array.

What is the HSTACK function?
The HSTACK function is a function in Sourcetable that merges two or more arrays together to make one larger array. The HSTACK function takes an array of arrays as its arguments and returns the larger array formed by appending the array arguments.
How do I use the HSTACK function?
Using the HSTACK function is simple. You just need to pass in an array of arrays as the arguments to the HSTACK function. The HSTACK function will then return the larger array formed by appending the array arguments.
What data types are supported by HSTACK?
The HSTACK function supports all data types that can be stored in an array including strings, integers, floats, and objects.
What is the output of the HSTACK function?
The output of the HSTACK function is a larger array formed by appending the array arguments.
Are there any limitations to the HSTACK function?
Yes, there are some limitations to the HSTACK function. The HSTACK function will only work on arrays of the same size and data type. It also cannot be used to combine different data types.