I would like to have R return a list of all files within a folder that contain one of a number of IDs. Below code sets the filepath and creates a list of the necessary IDs to search for, is there a simple way of having R loop through each file in the folder and return a list of files with at least one matching ID?
#Set filepath
MYFILEPATH <- "\\\\dcfnetwork\\data\\\\R\\Test Folder"
#set list of IDs to check for
IDList <- c("l21", "d66", "f53")