I have several questions:
1. What's the difference between isoMDS and cmdscale?
2. May I use asymmetric matrix?
3. Is there any way to determine optimal number of dimensions (in result)?
- 104,111
- 38
- 209
- 254
- 2,159
- 5
- 25
- 33
-
3You might want to consider breaking these up into 2-3 different questions. – JD Long Feb 26 '10 at 20:14
1 Answers
One of the MDS methods is
distance scalingand it is divided in metric and non-metric. Another one is theclassical scaling(also calleddistance geometryby those in bioinformatics). Classical scaling can be carried out in R by using the commandcmdscale. Kruskal's method of nonmetric distance scaling (using the stress function and isotonic regression) can be carried out by using the commandisoMDSin library MASS. The standard treatment ofclassical scalingyields an eigendecomposition problem and as such is the same as PCA if the goal is dimensionality reduction. Thedistance scalingmethods, on the other hand, use iterative procedures to arrive at a solution.If you refer to the distance structure, I guess you should pass a structure of the class
distwhich is an object with distance information. Or a (symmetric) matrix of distances, or an object which can be coerced to such a matrix using as.matrix(). (As I read in the help, only the lower triangle of the matrix is used, the rest is ignored).(for classical scaling method): One way of determining the dimensionality of the resulting configuration is to look at the eigenvalues of the
doubly centeredsymmetric matrix B (= HAH). The usual strategy is to plot the ordered eigenvalues (or some function of them) against dimension and then identify a dimension at which the eigenvalues become “stable” (i.e., do not change perceptively). At that dimension, we may observe an “elbow” that shows where stability occurs (for points of a n-dimensional space, stability in the plot should occur at dimension n+1). For easier graphical interpretation of a classical scaling solution, we usually choose n to be small, of the order 2 or 3.
- 29,749
- 18
- 107
- 146