I have 20 different tibbles (called N1 to N20), each with 9 columns and about 2 Million rows in R.
In column number 8 (type: integer) I want to change the date. The entry in every column number 8 of each tibble is always the same, it's always number "14190"
I dont want to write :
N1[,8] <- lapply(N1[,8], function(x) format(as.Date(as.numeric(x),origin="1970-01-01"), "%Y-%m-%d"))
N2[,8] <- lapply(N2[,8], function(x) format(as.Date(as.numeric(x),origin="1970-01-01"), "%Y-%m-%d"))
N3[,8] <- lapply(N3[,8], function(x) format(as.Date(as.numeric(x),origin="1970-01-01"), "%Y-%m-%d"))
...
N20[,8] <- lapply(N20[,8], function(x) format(as.Date(as.numeric(x),origin="1970-01-01"), "%Y-%m-%d"))
My first idea was to set a list from N1-N20 but then my function got a problem because it wants integers as argument.
Is there any quick solution? Maybe without lapply?
Thank you!