title: "invalid argument type" error with all.equal. R
body: <p>all.equal() gives an "invalid argument type" error with these data. Any idea?</p>
  
  <pre><code>&gt;matrix1
    1 2   3 4   5
  1 0 0 0.0 0 0.0
  2 1 0 0.0 0 0.0
  3 0 1 0.0 0 0.0
  4 0 0 0.5 0 0.5
  5 0 0 1.0 0 0.0
  &gt;rowSums(matrix1)
  1 2 3 4 5 
  0 1 1 1 1 
  &gt; !all.equal(as.vector(rowSums(matrix1)), as.vector(rep(1, nrow(matrix1))), check.attributes=FALSE)
  Error in !all.equal(as.vector(rowSums(matrix1)), as.vector(rep(1,  : 
    invalid argument type
  </code></pre>