Suppose w <- 11:20
At this time, you can make the vector to be a matrix by adding its dimension attribute by using dim function.
dim(w) <- c(2,5)
OR dim(w) <- c(nrow=2, ncol=5)
Suppose w <- 11:20
At this time, you can make the vector to be a matrix by adding its dimension attribute by using dim function.
dim(w) <- c(2,5)
OR dim(w) <- c(nrow=2, ncol=5)