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
답변 (1개)
Peter Perkins
2011년 12월 28일
>> 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.
카테고리
도움말 센터 및 File Exchange에서 Dimensionality Reduction and Feature Extraction에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!