フィルターのクリア

how to calculate total hamming distance?

2 ビュー (過去 30 日間)
sara
sara 2014 年 11 月 11 日
コメント済み: sara 2014 年 11 月 11 日
hi guys i have this code which i was running to calculate hamming distance:
D = pdist(AA,'minkowski',1);
D_matrix = squareform(D);
Z = [0; diag(D_matrix,1)]
the output of this file is the hamming distance for my matrix as ( 0 2 2 3 4 ...) i want to calculate the total hamming distance of it. which is the summation of hamming distance (0+2+2+3+4...) how to do it?

採用された回答

the cyclist
the cyclist 2014 年 11 月 11 日
sumZ = sum(Z)
  1 件のコメント
sara
sara 2014 年 11 月 11 日
thanks man

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

その他の回答 (0 件)

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by