フィルターのクリア

indexing of a matrix

1 回表示 (過去 30 日間)
deji
deji 2011 年 11 月 9 日
hi, i av a 200*3588 matrix and i want to index paired numbers from each column.is there a matlab function that will help me do it or do i av to do it manually? thanks in advance
  1 件のコメント
Fangjun Jiang
Fangjun Jiang 2011 年 11 月 9 日
Use a small matrix to explain what you need.

サインインしてコメントする。

採用された回答

Walter Roberson
Walter Roberson 2011 年 11 月 9 日
rowidx = [rowidx1, rowidx2, rowidx3, ... rowidx200];
matind = sub2ind(size(YourMatrix), [rowidx; 1+rowidx], repmat(1:size(YourMatrix,2), 2, 1) );
pairedValues = YourMatrix(matind);

その他の回答 (0 件)

カテゴリ

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

製品

Community Treasure Hunt

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

Start Hunting!

Translated by