0

I have a data.frame called X with 14 columns and 48 rows. Stata's command for what I want to do is -expand- https://www.stata.com/manuals13/dexpand.pdf

A simplified version of what I want to do is.

  1. I have this data.framework (some random numbers):
      1  -1   0   4   2

      5   0  -1   2  -2

      3   2   0   1   2

  1. and I want to expand it 40 times, like doing rbind(X, X, X, ..., X)
      1  -1   0   4   2

      5   0  -1   2  -2

      3   2   0   1   2

      1  -1   0   4   2

      5   0  -1   2  -2

      3   2   0   1   2

      ...

      1  -1   0   4   2

      5   0  -1   2  -2

      3   2   0   1   2

Thank you!!

Allan Cameron
  • 91,771
  • 6
  • 28
  • 55

0 Answers0