title: Looking for fast cointegration function in R
body: <p>I am looking for a cointegration function that can execute cointegration test faster than functions available in <code>urca</code> library.</p>
  <p>Here is my test data from <code>timeSeries</code> package</p>
  <pre><code>library(timeSeries)
  data = LPP2005REC
  test_dt = data.table(data$MPI, data$SBI)
  </code></pre>
  <p>Here are the performance results of cointegration test using <code>urca</code> library.</p>
  <pre><code>library(urca)
  microbenchmark::microbenchmark(
  ca.po.pu = summary(urca::ca.po(test_dt, type = &quot;Pu&quot;, demean = &quot;trend&quot;, lag = &quot;short&quot;))@testreg$coefficients[2, 1],
  ca.jo = urca::ca.jo(test_dt, type = &quot;trace&quot;, ecdet = &quot;trend&quot;, spec = &quot;longrun&quot;, K = 2)@teststat[1],
  times = 5)
  Unit: milliseconds
       expr      min       lq      mean    median        uq       max neval cld
   ca.po.pu 9.105962 9.509942 10.777335 10.651319 11.219605 13.399847     5   b
      ca.jo 3.646501 3.959293  4.581624  4.926513  5.043406  5.332409     5  a 
  </code></pre>
  <p>I will appreciate it if someone can suggest a faster cointegration test function.</p>