Array Transformation functions

ROWS_N_TIMES

Reference

» N/A

About

Repeats each Row ‘N’ times.

Inputs:

  • array : array to repeat
  • n_times_count : number of times to repeat each row in the array

Code

M.S. Excel
ROWSRPT_N_TIMES = LAMBDA(array, n_times_count,
  LET(
      a, array,
      n, n_times_count,
      INDEX(a, TOCOL(IF(n >= SEQUENCE(, MAX(n)), SEQUENCE(ROWS(a)), NA()), 2), SEQUENCE(, COLUMNS(a)))
  )
 );