This function swaps the values of both vectors. This function works only if both vectors have equal length.
Usage
swapVector(x,y)
Arguments
x
A vector.
y
A vector.
Value
Swapped vectors x and y.
Details
If the lengths of both vectors are not same, it generates an error. This function swaps the vectors in memory(like pass by reference), it does not return the vectors, but interchanges their values.