Table of Contents
The SEQUENCE function in Google Sheets allows users to easily generate a sequence of numbers or dates in a spreadsheet. By simply specifying the starting number, the number of rows or columns, and the step size, the SEQUENCE function will automatically generate a sequential list of numbers or dates. This function is particularly useful for creating organized lists or charts and can save users time and effort in manually inputting data.
SEQUENCE function
The SEQUENCE function returns an array of sequential numbers, such as 1, 2, 3, 4.
Parts of a SEQUENCE function
SEQUENCE(rows, columns, start, step)
| Part | Description |
rows | Required. The number of rows to return |
columns | Optional. The number of columns to return. If omitted, the returned array will have one column. |
start | Optional. The number to start the sequence at. If omitted, the sequence will start at 1. |
step | Optional. The amount to increase/decrease each number in the sequence. If omitted, the sequence will increase by 1. |
Sample formulas
Example 1: SEQUENCE(2)
Example 2: SEQUENCE(2, 3)
Example 3: SEQUENCE(2, 3, 3, 2)
Example 4: SEQUENCE(2, 3, 10, -1)
Notes
If columns is omitted, the resulting array will be a vertical list. If a horizontal list is needed, either specify rows as 1 and specify columns or transpose the vertical result.
Result for A1=SEQUENCE(2)
| A | B | |
| 1 | 1 | |
| 2 | 2 |
Result for A1= SEQUENCE(2, 3)
| A | B | C | |
| 1 | 1 | 2 | 3 |
| 2 | 4 | 5 | 6 |
| 3 |
Result for A1= SEQUENCE(2, 3, 3, 2)
| A | B | C | |
| 1 | 3 | 5 | 7 |
| 2 | 9 | 11 | 13 |
| 3 |
Result for A1= SEQUENCE(2, 3, 10, -1)
| A | B | C | |
| 1 | 10 | 9 | 8 |
| 2 | 7 | 6 | 5 |
| 3 | 4 | 3 | 2 |
Related functions
- MUNIT: The MUNIT function returns a unit matrix of size dimension x dimension.
- RANDARRAY: The RANDARRAY function generates an array of random numbers between 0 and 1.
Cite this article
stats writer (2024). How can I use the SEQUENCE function in Google Sheets to automatically generate a sequence of numbers or dates?. PSYCHOLOGICAL SCALES. Retrieved from https://scales.arabpsychology.com/stats/how-can-i-use-the-sequence-function-in-google-sheets-to-automatically-generate-a-sequence-of-numbers-or-dates/
stats writer. "How can I use the SEQUENCE function in Google Sheets to automatically generate a sequence of numbers or dates?." PSYCHOLOGICAL SCALES, 30 Jun. 2024, https://scales.arabpsychology.com/stats/how-can-i-use-the-sequence-function-in-google-sheets-to-automatically-generate-a-sequence-of-numbers-or-dates/.
stats writer. "How can I use the SEQUENCE function in Google Sheets to automatically generate a sequence of numbers or dates?." PSYCHOLOGICAL SCALES, 2024. https://scales.arabpsychology.com/stats/how-can-i-use-the-sequence-function-in-google-sheets-to-automatically-generate-a-sequence-of-numbers-or-dates/.
stats writer (2024) 'How can I use the SEQUENCE function in Google Sheets to automatically generate a sequence of numbers or dates?', PSYCHOLOGICAL SCALES. Available at: https://scales.arabpsychology.com/stats/how-can-i-use-the-sequence-function-in-google-sheets-to-automatically-generate-a-sequence-of-numbers-or-dates/.
[1] stats writer, "How can I use the SEQUENCE function in Google Sheets to automatically generate a sequence of numbers or dates?," PSYCHOLOGICAL SCALES, vol. X, no. Y, ص Z-Z, June, 2024.
stats writer. How can I use the SEQUENCE function in Google Sheets to automatically generate a sequence of numbers or dates?. PSYCHOLOGICAL SCALES. 2024;vol(issue):pages.
