I want to concatenate the items of a character vector:
vector<-c("Hello", "World", "Today") vector [1] "Hello" "World" "Today" I want to insert a comma between all the items and maintain the ("") of each character. The final result should look like this:
"Hello","World","Today" Is it possible to do this in R, I tried with paste and paste0, but so far without any luck!
paste(vector,collapse = ",")will work, but do not name vector'svectorbecause it is a function in R.