title: Extracting conditional data from multiple csv files with python
body: <p>I'm new to python and I would like to extract rows from several csv (better tsv) files in one new excel file with a new column defining the source of the data.</p>
  <p>My code for doing it just for one file is:</p>
  <pre><code>import pandas as pd
  
  df = pd.read_csv('C:/Users/filename.tsv', names=['c1', 'c2', 'c3', 'c4'], delimiter='\t')
  
  result = df.loc [(df['c2'].isin(['name']))]
  
  result.to_excel(r'C:/Users/filenamenew.xlsx')
  </code></pre>
  <p>But how do I do it for several files? like filename1.tsv; filename2.tsv; filename3.tsv...</p>