Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- cols = [*df]
- with open('test.txt', 'w') as f:
- for data in df.to_numpy(copy=False).tolist():
- json.dump(dict(zip(cols, data)), f)
- f.write('\n')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement