Error with mdscale

I was trying to use nonclassical MDS function 'mdscale'. I have read that non classical MDS allows incomplete distance matrix to use.I have used a dissimilarity matrix (dist_mat) with few missing entries, replaced by NaN.This is in upper triangular form for five subjects as shown below.Thus 'dist_mat' has 10 distances with unknowns represented by NaN. For Ex: dist_mat=[3.9714;NaN;NaN;3.6492;NaN ; 2.8870 ; NaN ; NaN ; NaN ;NaN] I am getting error with mdscale(dist_mat,2) as- "Cannot initialize with 'cmdscale' when there are zero weights or missing data. Initialize with 'random' or provide explicit starting points" I did not understand what this means, why cmdscale here? How to assign weights and how to initialize with 'random'? Please help, Thanks

Answers (1)

Peter Perkins
Peter Perkins on 28 Dec 2011
>> help mdscale
mdscale Non-Metric and Metric Multidimensional Scaling.
[snip]
'Start' - Method used to choose the initial configuration of points
for Y. Choices are:
'cmdscale' - Use the classical MDS solution. This is the default.
'cmdscale' is not valid when there are zero weights.
'random' - Choose locations randomly from an appropriately
scaled P-dimensional normal distribution with
uncorrelated coordinates.
matrix - An N-by-P matrix of initial locations. In this
case, you can pass in [] for P, and mdscale infers P
from the second dimension of the matrix. You can also
supply a 3D array, implying a value for 'Replicates'
from the array's third dimension.

1 Comment

cvp
cvp on 30 Dec 2011
Thanks Mr. Peter Perkins,
I have seen its help but I could not understand. Actually here I want to know whether we can use an incomplete distance matrix? If yes how? Please give a small example.
According to my understanding cmdscale is used in classical MDS and mdscale in nonclassical MDS.
In mdscale where to use random,please explain with a small example

Sign in to comment.

Categories

Tags

Asked:

cvp
on 28 Dec 2011

Community Treasure Hunt

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

Start Hunting!