title: R error in evaluating the argument. Arguments imply differing number of rows
body: <p>I've tried to research the answer and I've found something close to my error but not similar enough to help me. My code is as follows:</p>
  
  <pre><code>setwd("Directory")
  require(XLConnect)
  wb &lt;- loadWorkbook("workbook.xlsx")
  st = readWorksheet(wb, sheet = getSheets(wb))
  
  summary(lm(X36~Temp.C., data=st))
  </code></pre>
  
  <p>Where X36 is a column within the Excel file. </p>
  
  <p>The error I'm getting is:</p>
  
  <pre><code>"Error in summary(lm(X36 ~ Temp.C., data = st)) : 
   error in evaluating the argument 'object' in selecting a method for 
  function 'summary': Error in data.frame(Info = list(Trial.. = c("Purpose: ", 
  "Cure: ", "Cond: ",  : 
   arguments imply differing number of rows: 12, 0, 7, 5, 10, 17, 3, 500, 25, 31, 8"
  </code></pre>
  
  <p>What I'm trying to do is create a data frame so I can run a <code>lm</code> on different columns. I believe the problem might be there being different sheets of differing amounts of rows within them but I'm not sure.</p>