I have 8 CSV files all in the same directory, and need them importing into a single data frame in R. They all follow the same naming convention, "dataUK_1.csv", "dataUK_2.csv" etc., and have the exact same structure in terms of columns.
I've managed to create a vector of all the file names (including the full directory) by using:
files = list.files("/Users/iarwain/Data", pattern=".csv", full.names=T)
I'm just not sure how to pass these names to the read.csv command so that it loops 8 times, importing each file and adding its content as new rows into a single data frame, so that the end result is one data frame containing all rows of data from the 8 CSVs.
Thanks!