title: add a row in pandas dataframe without knowing number of columns
body: <p>I'm new to python and I would appreciate if you give me an answer as soon as possible.</p>
  
  <p>I'm processing a file containing reviews for products that can belong to more than 1 category. What I need is to group the review ratings by the categories, and date at the same time. Since I don't know the exact number of categories, or dates in advance, I need to add rows and columns as I'm processing the reviews data (50 GB file). </p>
  
  <p>I've seen how I can add columns, however my trouble is adding a row without knowing how many columns are currently in the dataframe. </p>
  
  <p>Here is my code:</p>
  
  <pre><code>    list1=['Movies &amp; TV', 'Books']    #categories so far
      dfMain=pandas.DataFrame(index=list1,columns=['2002-09']) #only one column at the beginnig
      print(dfMain)
  </code></pre>
  
  <p>This is what dfMain looks like:</p>
  
  <p><a href="https://i.stack.imgur.com/CmB5b.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/CmB5b.jpg" alt="enter image description here"></a></p>
  
  <p>If I want to add a column, I simply do this:
  dfMain.insert(0, date, 0) #where date is in format like '2002-09'</p>
  
  <p>But if I want to add a new category(row) and fill all the dates(columns) with zeros? How do I do that? I've tried with method append, but it asks for all the columns as parameters. Method Insert doesn't seem to work either..</p>