title: I need to add headers to file , but I am losing first row of data after using `df.columns` in Pandas?
body: <p>I am new to Pandas.
  My txt file does not have headers.
  Hence I am adding it explicitly.
  However after using <code>df.columns</code>, I am losing the top row of data, how can I avoid losing the top row/ first row ?</p>
  <p><strong>Code</strong>:</p>
  <pre><code>df1 = pd.read_csv('ABC.txt',sep = '\t')
  headers =  ['name', 'age', 'group']
  df1.columns = headers
  df1.to_csv('newABC.txt', sep = '\t')
  </code></pre>
  <p><strong>Input</strong>:
  <a href="https://i.stack.imgur.com/Qiyg4.png" rel="nofollow noreferrer">Input</a></p>
  <p><strong>Output</strong>:
  <a href="https://i.stack.imgur.com/foZOg.png" rel="nofollow noreferrer">output</a></p>
  <p><strong>Expected Output</strong>:
  <a href="https://i.stack.imgur.com/ojCP3.png" rel="nofollow noreferrer">expected output</a></p>