title: Create dataframe with repeating string from scratch in R
body: <p>I would like to create a dataframe that essentially would look something like this
  <a href="https://i.stack.imgur.com/S5Cpm.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/S5Cpm.png" alt="enter image description here" /></a></p>
  <p>Repeating the period from 1 to 10 and assigning the ID 42,574 times
  so that I would end up with a 425,740 row dataframe.</p>
  <p>I tried to create a dataframe using the following code</p>
  <pre><code>periodstring &lt;- as.numeric(gl(10, 42574))
  periods &lt;- as.data.frame(periodstring)
  </code></pre>
  <p>but that sorts the numbers and other approaches did not quiete work. Is there a simple way to do this?</p>
  <p>Thanks in advance.</p>