outputfile += str(i + 2)
merged_data = merged_data.fillna(0)
store.put('/tmp' + str(counter) + '/' + outputfile, merged_data)
store.flush()
to_remove = [file for file in list(store.keys()) if 'tmp' + str(counter) + '/' not in
    file]
for file in to_remove:
    store.remove(file)
flist = list(store.keys())
store.close()
return merged_data
Outer join in Python for thousands of large tables