ARRAY1DTO2D

=ARRAY1DTO2D(array,divisor)

array
array to be transformed
divisor
the number of divisions to split the array into

ARRAY1DTO2D Splits a 1D array into a 2D array of equal heights given a divisor.

RicoS

Board Regular
Joined
May 1, 2019
Messages
62
ARRAY1DTO2D Splits a 1D array into a 2D array of equal heights given a divisor (e.g. array of 30 rows and a divisor of 3 will return the 1D array to a 3x10 2D array).

Excel Formula:
=LAMBDA(array,divisor,LET(a,array,d,divisor,s,SEQUENCE(d,ROWS(a)/d),return,INDEX(a,s,1),return))

Lambda - Last Cell and Split.xlsx
BCDEFGH
1Original ArrayResized array
21123
32456
43789
54101112
65
76
87
98
109
1110
1211
1312
Sheet1
Cell Formulas
RangeFormula
B2:B13B2=SEQUENCE(12)
F2:H5F2=ARRAY1DTO2D(B2#,4)
Dynamic array formulas.
 
Upvote 0

Forum statistics

Threads
1,224,829
Messages
6,181,218
Members
453,024
Latest member
Wingit77

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top