title: cbind before rbind, or rbind before cbind?
body: <p>Say I have 20 frames on a 4-node H2O cluster: a1..a5, b1..b5, c1..c5, d1..d5. And I want to combine them into one big frame, from which I will build a model.</p>
  
  <p>Is it better to combine sets of columns, then combine rows:</p>
  
  <pre><code>h2o.rbind(
    h2o.cbind(a1, b1, c1, d1),
    h2o.cbind(a2, b2, c2, d2),
    h2o.cbind(a3, b3, c3, d3),
    h2o.cbind(a4, b4, c4, d4),
    h2o.cbind(a5, b5, c5, d5)
    )
  </code></pre>
  
  <p>Or, to combine the rows first, then the columns:</p>
  
  <pre><code>h2o.cbind(
    h2o.rbind(a1, a2, a3, a4, a5),
    h2o.rbind(b1, b2, b3, b4, b5),
    h2o.rbind(c1, c2, c3, c4, c5),
    h2o.rbind(d1, d2, d3, d4, d5)
    )
  </code></pre>
  
  <p>For the sake of argument, 1/2/3/4/5 might each represent one month of data, which is why they got imported separately. And a/b/c/d are different sets of features, which again explains why they were imported separately. Let's say, a1..a5 have 1728 columns, b1..b5 have 113 columns, c1..c5 have 360 columns, and d1..d5 is a single column (the answer I'll be modelling). (Though I suspect, as H2O is a column database, that the relative number of columns in a/b/c/d does not matter?)</p>
  
  <p>By "better" I mean quicker, but if there is a memory-usage difference in one or the other, that would also be good to know: I'm mainly interested in the Big Data case, where the combined frame is big enough that I wouldn't be able to fit it in the memory of just a a single node.</p>