for v in enumerate (["20170106", "20170113", "20170127", "20170203", "20170210", "20170224", "20170303", "20170310", "20170324", "20170331"])
Year17 = "/Users/Name/Desktop/Datas/" + v
csvFiles = glob.glob (os.path.join (Year17, "*.csv"))
df = (pd.read_csv(i) for i in csvFiles)
df = pd.concat (df, ignore_index=True)
The subfolders "20170106", "20170113", "20170127", etc... which are inside the folder "Year17"
This code works good, but:
- How can I avoid writing all the subfolders names "20170106", "20170113", "20170127", etc... in the for sentence? Maybe os.walk? How it would be?