Fix create_participants_files.R to handle numeric PIDs

pull/149/head
JulioV 2021-06-22 16:37:22 -04:00 committed by Weiyu
parent 9593667f38
commit 5892b6d838
1 changed files with 1 additions and 1 deletions

View File

@ -73,7 +73,7 @@ participants %>%
file_lines <-readLines("./config.yaml") file_lines <-readLines("./config.yaml")
for (i in 1:length(file_lines)){ for (i in 1:length(file_lines)){
if(startsWith(file_lines[i], "PIDS:")){ if(startsWith(file_lines[i], "PIDS:")){
file_lines[i] <- paste0("PIDS: [", paste(participants$pid, collapse = ", "), "]") file_lines[i] <- paste0("PIDS: ['", paste(participants$pid, collapse = "', '"), "']")
} }
} }
writeLines(file_lines, con = "./config.yaml") writeLines(file_lines, con = "./config.yaml")