title: random number generation from a copula using set.seed
body: <p>I'm running two sessions of RStudio on my laptop.</p>
  
  <p>When I ran</p>
  
  <pre><code>set.seed(1)
  runif(1)
  </code></pre>
  
  <p>twice in each session, four of them gave the same number 0.2655087.</p>
  
  <p>But if I generate random numbers from a copula using <code>rCopula</code> function of <code>copula</code> package, it does not work. It produces the same numbers if I run it twice within the same session, but different numbers in a different session.</p>
  
  <p>On session 1,</p>
  
  <pre><code>set.seed(5)  
  dat = rCopula(50, gumbelCopula(2.07, dim = 2))
  dat[1,]
  # [1] 0.7058623 0.3512414
  set.seed(5)  
  dat = rCopula(50, gumbelCopula(2.07, dim = 2))
  dat[1,]
  # [1] 0.7058623 0.3512414
  </code></pre>
  
  <p>On session 2,</p>
  
  <pre><code>set.seed(5)
  dat = rCopula(50, gumbelCopula(2.07, dim = 2))
  dat[1,]
  # [1] 0.2489993 0.6595176
  set.seed(5)
  dat = rCopula(50, gumbelCopula(2.07, dim = 2))
  dat[1,]
  # [1] 0.2489993 0.6595176
  </code></pre>
  
  <p>Why does it happen and how can I get the same numbers?</p>