Answers for "repeat each value in a vector in r"

R
0

repeat each value in a vector in r

> rep(c(2, 4, 2), each = 3)
[1] 2 2 2 4 4 4 2 2 2
Posted by: Guest on October-05-2021

Code answers related to "repeat each value in a vector in r"

Browse Popular Code Answers by Language