I use the "tuber" library for R. In this code snippet I load a file with IDs YouTube-channels and write the information to a vector. Next step in the loop I go through the ID and paste an array element (youtube channel) as an argument to the "list_channel_videos" function. The result of the function is a list with information about the channel. How can I write information about all channels sequentially to a csv file? If I use this code, information recorded only about the last channel from the array.
vtest <- read.csv2("tester.csv", header = FALSE) arrv <- as.matrix(vtest) arv <- as.vector(arrv) iterator <- 1 for (iterator in 1:length(arv)) { nv <- list_channel_videos(channel_id = arv[iterator]) write.csv2(nv, file="bb.csv", append = TRUE) }