MATLAB: Hi..i need to repeat rows and columns in matrix A

in matlab

A=[1 2 3 ;4 5 6 ] after answer: 1 1 4 4 2 2 5 5 3 3 6 6

Best Answer

Try this:
After = repelem(A', 1, 2)
After =
1 1 4 4
2 2 5 5
3 3 6 6
The repelem function was introduced in R2015a.