Created
June 7, 2017 23:07
-
-
Save ricklentz/2473972a14c295743a0e8005dda0517b to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import pandas as pd | |
| import os | |
| path =r'/home/wrk' # use your path | |
| allFiles = os.listdir(path) | |
| frame = pd.DataFrame() | |
| list_ = [] | |
| for file_ in allFiles: | |
| df = pd.read_csv(path + '/' + file_,index_col=None, header=0) | |
| list_.append(df) | |
| frame = pd.concat(list_) | |
| frame.to_csv(path + '/comb.csv', sep='\t', encoding='utf-8') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment