フィルターのクリア

how can i remove an element from a matrix

1 回表示 (過去 30 日間)
Imane hammou ouali
Imane hammou ouali 2019 年 4 月 14 日
コメント済み: Walter Roberson 2019 年 4 月 14 日
hello community,
i have a matrix A=[0 0 0;0.7 1 0.7] i want to remove the element 1 A(2,2) help please

回答 (1 件)

Ronny Landsverk
Ronny Landsverk 2019 年 4 月 14 日
If you want a representation of an empty element, use NaN (not a number).
A(2,2) = NaN;
  1 件のコメント
Walter Roberson
Walter Roberson 2019 年 4 月 14 日
And if replacing the location with some set value such as NaN or -9999 is not appropriate, then you have the problem that rectangular arrays cannot have "holes" in them.

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

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by