if (FALSE) {
# Merge all files in the main folder "raw_data"
# (which is in the current working directory)
raw_data <- read_bulk(directory = "raw_data")
# Merge files with file extension ".csv"
raw_data <- read_bulk(directory = "raw_data",
extension = ".csv")
# Merge all files stored in separate folders
# within the folder "raw_data"
raw_data <- read_bulk(directory = "raw_data",
subdirectories = TRUE)
# Merge all raw data stored in the folders "Session1"
# and "Session2" within the folder "raw_data"
raw_data <- read_bulk(directory = "raw_data",
subdirectories = c("Session1","Session2"))
# Merge tab separated data files and prevent
# character vectors from being converted to factors
raw_data <- read_bulk(directory = "raw_data",
fun=read.delim,stringsAsFactors=FALSE)
}
Run the code above in your browser using DataLab