.. highlightlang:: us .. index:: reshape .. _reshape: reshape ======= .. us.tag reshape ENGLISH :ref:`reshape` creates a copy of a matrix and changes the number of columns and rows. .. function:: mNew = reshape(mOld, n, m) .. us.return **Return Value** *mNew* is the copy of *mOld* with *n* rows and *m* columns. .. us.params **Parameters** .. uparam:: mOld *mOld* is a real, complex or string matrix with n * m elements. .. uparam:: n *n* is the number of rows of *nNew*. .. uparam:: m *m* is the number of columns of *nNew*. .. seealso:: :ref:`len`, :ref:`nr`, :ref:`nc` :sub:`id-254777`