Search
Code Directory
ASP
ASP.NET
C/C++
CFML
CGI/PERL
Delphi
Development
Flash
HTML
Java
JavaScript
Pascal
PHP
Python
SQL
Tools
Visual Basic & VB.NET
XML
New Code
 Vue Injector 3.3 Spectrum Analyzer pro Live 2019 Devart Excel Add-in for HubSpot 2.1 RentALLScript - Airbnb clone 2.2 SuiteCRM Theme Customization 7.11.6 iScripts NetMenus 3.1 iScripts EasyIndex 2.2 iScripts EasySnaps 2.0 Australia MyPost shipping For Magento 2 1.0.0 Australia Post eParcel For Magento 1.1.1 Source Control for SQL Server 2.0 Answers phpSoftPro 3.12 Exlcart 2.0 School College ERP 1.3.2 White-label Grocery Delivery App Solution 2.0
Top Code
 phpEnter 5.1. Quick Maps For Dynamics CRM 3.1 Single Leg MLM 1.2.1 Azizi search engine script PHP 4.1.10 Paste phpSoftPro 1.4.1 Extreme Injector 3.7 Deals and Discounts Website Script 1.0.2 Solid File System OS edition 5.1 Classified Ad Lister 1.0 Aglowsoft SQL Query Tools 8.2 Invoice Manager by PHPJabbers 3.0 ICPennyBid Penny Auction Script 4.0 PHP Review Script 1.0 ATN Resume Finder 2.0 ATN Site Builder 3.0
Report About distmat 1.0

D = DISTMAT(X,Y) for matrices X and Y returns the distance matrix where the (i,j)th entry is the d-norm distance between the ith and jth row of X and Y respectively.

DISTMAT(X,Y,d) computes a specific d-norm distance. Default=2

[D,XI,YI]=DISTMAT(X,Y,d,var) gives the indices of the sorted values of matrix D depending on var ('ascend' or 'descend') in relation to both X and Y.

EXAMPLE:
X=[5 1; 8 1; 1 9];
Y=[7 1; 1 1];

[D,XI,YI]=DISTMAT(X,Y)

D=[2 4; 1 7; 10 8]
XI=[1 2; 1 2; 2 1]
YI=[2 1 3; 1 2 3]

The distance between X(3,:)=[1 9] and Y(2,:)=[1 1] is D(3,2)=8
Starting with Y(1,:) from smallest to largest distance away is X([2 1 3],:)

Back