From where do I insert the transpose operator for matrix operation ?

1 回表示 (過去 30 日間)
Shubham Bhattacharjee
Shubham Bhattacharjee 2020 年 3 月 22 日
To convert a row matrix into a coloumn matrix I need to perform x = x(transpose). But how to insert the TRANSPOSE operator ?

採用された回答

Ameer Hamza
Ameer Hamza 2020 年 3 月 22 日
編集済み: Ameer Hamza 2020 年 3 月 22 日
In MATLAB, transpose is indicated by apostrophe symbol ('). See: https://www.mathworks.com/help/matlab/ref/transpose.html
x = x';

その他の回答 (1 件)

Sriram Tadavarty
Sriram Tadavarty 2020 年 3 月 22 日
Hi Shubham,
You can directly use (') operator
% For example
x = rand(3,5);
xTranspose = x'; % size will be 5 x 3
% OR through transpose function
xTrans = transpose(x);
For more details, go through transpose.
Hope this helps.
Regards,
Sriram

カテゴリ

Help Center および File ExchangeString についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by