# RANDARRAY Function

> Create a spilled array of random numbers with RANDARRAY in TX Sheet Control: rows, columns, minimum, maximum, whole numbers and #NUM! and #VALUE! errors.

- **Product:** TX Sheet Control
- **Section:** Documentation
- **Kind:** Function
- **Path:** TX Sheet Control > API Reference > Formula Functions > RANDARRAY Function
- **257 words**
- **Web URL:** https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/randarray/
- **LLMs URL:** https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/randarray/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/randarray/llms-full.txt

---

Return an array of random numbers that spills into the cells next to the formula. `rows` and `columns` set the size of the array (1 when omitted), `start_or_min` and `step_or_max` the smallest and the largest number (0 and 1 when omitted), and `whole_number` TRUE returns integers and FALSE or omitted decimal numbers. A `rows` or `columns` value less than 1 returns `#NUM!`, and a smallest number greater than the largest returns `#VALUE!`.

### Syntax

```text
RANDARRAY(rows, columns, start_or_min, step_or_max, whole_number)
```

Category: Lookup. Minimum arguments: 0. Maximum arguments: 5.

Available for supported offline calculation.

### Examples

```text
=RANDARRAY(2,3,1,1)
```

The formula returns an array of 2 rows and 3 columns with 1 in every cell, because the smallest and the largest number are both 1.

Cell and range examples require appropriate input values in the referenced cells. Handle invalid arguments, formula errors and array and spill constraints.

### See Also

- [Formulas](https://docs.textcontrol.com/tx-sheet-control/spreadsheets/formulas/llms-full.txt)
- [Custom Functions and Formula Data](https://docs.textcontrol.com/tx-sheet-control/spreadsheets/custom-functions/llms-full.txt)

---

## Nearby

- **Previous:** [RAND Function](https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/rand/llms-full.txt)
- **Next:** [RANDBETWEEN Function](https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/randbetween/llms-full.txt)
