R:多维尺度
我有几个问题:
1. isoMDS 和 cmdscale 有什么区别?
2.我可以使用非对称矩阵吗?
3. 有什么方法可以确定最佳维度数(结果)?
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)?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
MDS 方法之一是距离缩放,它分为公制和非公制。另一种是
经典缩放
(生物信息学也称为距离几何
)。经典缩放可以在 R 中使用命令cmdscale
进行。 Kruskal 的非度量距离缩放方法(使用应力函数和等渗回归)可以通过使用 MASS 库中的命令isoMDS
来执行。经典缩放的标准处理会产生特征分解问题,因此如果目标是降维,则与 PCA 相同。另一方面,距离缩放方法使用迭代过程来得出解决方案。
如果你引用距离结构,我想你应该传递一个
dist
类的结构,它是一个带有距离信息的对象。或者是距离的(对称)矩阵,或者可以使用 as.matrix() 强制转换为此类矩阵的对象。 (正如我在帮助中读到的,仅使用矩阵的下三角形,其余部分被忽略)。(对于经典缩放方法):确定结果配置维数的一种方法是查看
双中心
对称矩阵 B (= HAH) 的特征值。通常的策略是根据维度绘制有序特征值(或它们的某些函数),然后确定特征值变得“稳定”(即不会在感知上发生变化)的维度。在该维度上,我们可以观察到一个“肘部”,它显示了稳定性发生的位置(对于 n 维空间的点,图中的稳定性应发生在 n+1 维处)。为了更容易地对经典缩放解决方案进行图形解释,我们通常选择 n 较小,大约为 2 或 3。One of the MDS methods is
distance scaling
and it is divided in metric and non-metric. Another one is theclassical scaling
(also calleddistance geometry
by 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 commandisoMDS
in library MASS.The standard treatment of
classical scaling
yields an eigendecomposition problem and as such is the same as PCA if the goal is dimensionality reduction. Thedistance scaling
methods, 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
dist
which 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 centered
symmetric 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.