convert specific vector to vector in one direction

回答 (3 件)

James Tursa
James Tursa 2016 年 2 月 19 日
編集済み: James Tursa 2016 年 2 月 19 日

0 投票

a = av(1:2,1:2);
If this simple solution is not what you are looking for then please give more details in your question.
Based on your reply it looks like you simply want the top half of your matrix. So try this:
[m n] = size(av);
a = av(1:(m/2),:);
muhammad ismat
muhammad ismat 2016 年 2 月 19 日

0 投票

i have a vector as av=[1 2;5 6;7 8;4 3;9 8;6 7;2 1;6 5;8 7;3 4;8 9;7 6] i want to a=[1 2;5 6;7 8;4 3;9 8;6 7]
muhammad ismat
muhammad ismat 2016 年 2 月 19 日

0 投票

that's right , thank you very much

カテゴリ

タグ

質問済み:

2016 年 2 月 19 日

回答済み:

2016 年 2 月 19 日

Community Treasure Hunt

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

Start Hunting!

Translated by