title: How to get a frequency table of all columns of complete data frame in R?
body: <p>I want to create a frequency table from a data frame and save it in excel. Using <code>table()</code> function i can only create frequency of a particular column. But I want to create frequency table for all the columns altogether, and for each column the levels or type of variables may differ too. Like kind of summary of a data frame but there will not be mean or other measures, only frequencies.
  I was trying something like this</p>
  
  <pre><code> for(i in 1:230){
   rm(tb)
   tb&lt;-data.frame(table(mydata[i]))
   tb2&lt;-cbind(tb2,tb)
   }
  </code></pre>
  
  <p>But it's showing the following Error</p>
  
  <blockquote>
    <p>Error in data.frame(..., check.names = FALSE) :    arguments imply
    differing number of rows: 15, 12</p>
  </blockquote>
  
  <p>In place of <code>cbind()</code> I also used <code>data.frame()</code> but the Error didn't changed.</p>