How we can merge two or more vectors in R?Explain with an example

439    Asked by JamesWILLIAMS in Data Science , Asked on Jan 2, 2020
Answered by James WILLIAMS

For merging two or more vectors, we use append() function which is a built in function in R. Let us define two vectors

v=c(10,20,30,40)

v2=c(50,60,70,80)

To merge these two vectors we can do the following

append(v,v2)

This will give the following output

[1] 10 20 30 40 50 60 70 80



Your Answer

Interviews

Parent Categories