title: cor.test R Error incompatible dimensions
body: <p>I would like to generate correlations between years in a dataset in R, however I keep getting the following error:</p>
  
  <pre><code>cor.test(y2013$CA,y2011$CA, method="spearman", use="complete")
  </code></pre>
  
  <p>Error in cor(x, y, use = use, method = method) : incompatible dimensions
  In addition: Warning message:
  In cbind(x, y) :
    number of rows of result is not a multiple of vector length (arg 2)</p>
  
  <p>y2013 and y2011 are not the same in length, however I thought by using the command "complete" this would eliminate this problem</p>