How to simplify the for loops and if statement in this code

1 回表示 (過去 30 日間)
STEFAN-PAMFILOIU IULIANA
STEFAN-PAMFILOIU IULIANA 2020 年 6 月 19 日
コメント済み: dpb 2020 年 6 月 23 日
How to simplify for loops and if statements.
  1 件のコメント
dpb
dpb 2020 年 6 月 23 日
Please restore the original post -- there's no context for others going forward now.

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

採用された回答

dpb
dpb 2020 年 6 月 19 日
Straightahead w/o trying to save some recomputations that could be done by complements--
k=[sum(A==B & A==0,'all') sum(A==B & A~=0,'all');sum(A~=B & A==0,'all') sum(A==B & A==1,'all')];

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeCorrelation and Convolution についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by