how to append a new row and column to a matrix in R code example Example: add row to matrix r MatrixB <- rbind(MatrixA, c(10,11,12))