how to create a matrix from another

How would i create a matrix that is the last column and the 2nd and 4th row of matrix x?

回答(2 个)

M = x(:, [end 2 4])
This is pretty basic stuff in MATLAB and you have other similar questions too. I ssuggest you to read about array indexing: https://www.mathworks.com/help/matlab/math/array-indexing.html.

此问题已关闭。

产品

版本

R2020a

标签

提问:

2020-9-20

关闭:

2021-8-20

Community Treasure Hunt

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

Start Hunting!

Translated by