title: How to get the results of dataframe appended to a single csv file
body: <p>I have a dataset with 5 columns from which the 2-column, 3-column and 4-column combinations are retrieved using the below code. I would like to get all these results in a single csv file. I'm new to using lists- can anyone help me with this.</p>
  
  <pre><code>df2 =[df[list(pair)] for pair in list(iter.combinations(df.columns, 2))]
  df3 =[df[list(pair)] for pair in list(iter.combinations(df.columns, 3))]
  df4 =[df[list(pair)] for pair in list(iter.combinations(df.columns, 4))]
  </code></pre>
  
  <p>I tried using the below but getting an exception that lists doesn't have an attribute to_csv</p>
  
  <pre><code>df2.to_csv(export_file, mode = 'w', index=False)
  df3.to_csv(export_file, mode = 'a', index=False)
  df4.to_csv(export_file, mode = 'a', index=False)
  </code></pre>
  
  <p>Expected results would be to get all the results of df2, df3 and df4 appended in a single csv file. </p>