Distance from points to points.

1 回表示 (過去 30 日間)
Francesco
Francesco 2014 年 2 月 5 日
編集済み: Francesco 2014 年 3 月 22 日
It's possible to read these coordinates from a text file formatted in this way:
  2 件のコメント
Image Analyst
Image Analyst 2014 年 2 月 5 日
Isn't this a duplicate of http://www.mathworks.com/matlabcentral/answers/114838#answer_123302 which already has people responding?
Francesco
Francesco 2014 年 2 月 5 日
It's not exactly the same questions.

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

採用された回答

Walter Roberson
Walter Roberson 2014 年 2 月 5 日
The identifier would be the row index of D.
  4 件のコメント
Francesco
Francesco 2014 年 2 月 5 日
Thanks. In general If I have n points I have to do this, where rows is the numbers of rows of the txt file.
[X, Y] = ndgrid(1:rows);
identifiers = arrayfun(@(X,Y) sprintf('%d_%d', X, Y), X, Y, 'Uniform', 0);
How Can I use pdist? What can I enter as input?
Walter Roberson
Walter Roberson 2014 年 2 月 5 日
Your previous question asked about using identifiers of that form and defined what the identifiers should look like. This question asks about using linear identifiers of the form 1, 2, 3, ... 6 .... n*(n-1)/2. But you have not given any indication of how the two are to fit together.

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeStartup and Shutdown についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by