I have a file list similar to the list below
[1] "M601-M-2020-09.csv"
[2] "M601-M-2020-10-2.csv"
[3] "M601-M-2020-10.csv"
[4] "M601-M-2020-11.csv"
[5] "M601-M-2020-12-1.csv"
[6] "M601-M-2020-12.csv"
I only want to read files 1, 3, 4, 6 (it's about the file name structure).
So far, I have managed to prepare such a solution:
list.files (sciezka, pattern = paste0("^(M601-M-)(", rok, ").*\.csv$") )