powered by
Helper function to repeat a matrix by row
rep_row(x, n)
Matrix with vector x repeated n-times by rows.
vector to repeat
number of repetions
set.seed(1) rep_row(rnorm(5), 5)
Run the code above in your browser using DataLab