Skip to content

Load multiple files into single dataset #335

Answered by HYPERTONE
HYPERTONE asked this question in Q&A
Discussion options

You must be logged in to vote
import glob
import os

path = r'C:\IndianaJones'

all_files = glob.glob(os.path.join(path, "Antidote_to_poison*.csv"))
ds= rt.Dataset.concat_rows([rt.load_csv_as_dataset(f) for f in all_files)

That was easy.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by HYPERTONE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant