R中EQUAMAX旋转的主成分分析 [英] Principal component analysis with EQUAMAX rotation in R

查看:433
本文介绍了R中EQUAMAX旋转的主成分分析的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要对R中的EQUAMAX-rotation进行主成分分析(PCA).

I need to do a principal component analysis (PCA) with EQUAMAX-rotation in R.

不幸的是,我通常用于PCA的功能"principal()"不提供这种旋转.

Unfortunately the function "principal()" I use normally for PCA does not offer this kind of rotation.

我发现使用包GPArotation可能有某种可能,但我仍无法弄清楚如何在PCA中使用它.

I could find out that it may be possible somehow with the package GPArotation but I could not yet figure out how to use this in the PCA.

也许有人可以举一个如何做equamax-rotation PCA的例子?

Maybe someone can give an example on how to do an equamax-rotation PCA?

或者另一个提供直接使用equamax-rotation的软件包中的PCA函数吗?

Or is there a function for PCA in another package that offers the use of equamax-rotation directly?

谢谢您的帮助!

推荐答案

我猜您正在使用principal()的软件包psych具有旋转varimaxquatimaxpromaxobliminsimplimaxcluster,但不是equimax(心理 p.232),这是Varimax和Quartimax之间的折衷方案

The package psych from i guess you are using principal() has the rotations varimax, quatimax, promax, oblimin, simplimax, and cluster but not equimax (psych p.232) which is a compromise between Varimax and Quartimax

摘自STATA手册: mvrotate 第3页

excerpt from the STATA manual: mvrotate p.3

旋转标准

在下面的描述中,要旋转的矩阵表示为 A ,p表示A的行数,f表示 A 的列数(因素或组件).如果 A 是因子或pca的加载矩阵,则p是变量数,而f是因子或分量数.

In the descriptions below, the matrix to be rotated is denoted as A, p denotes the number of rows of A, and f denotes the number of columns of A (factors or components). If A is a loading matrix from factor or pca, p is the number of variables, and f is the number of factors or components.

仅适用于正交旋转的条件

varimaxvgpf施加正交的varimax旋转(Kaiser 1958). varimax最大化因子(A的列)内平方载荷的方差.它等效于cf(1/p)和oblimin(1). varimax是最流行的循环,是使用专用的快速算法实现的,并且忽略所有优化选项.指定vgpf可以切换到用于其他条件的通用GPF算法.

varimax and vgpf apply the orthogonal varimax rotation (Kaiser 1958). varimax maximizes the variance of the squared loadings within factors (columns of A). It is equivalent to cf(1/p) and to oblimin(1). varimax, the most popular rotation, is implemented with a dedicated fast algorithm and ignores all optimize options. Specify vgpf to switch to the general GPF algorithm used for the other criteria.

quartimax使用quartimax准则(Harman 1976). quartimax最大化方差 变量( A 行)中的平方加载.对于正交旋转,quartimax等效于cf(0)和oblimax.

quartimax uses the quartimax criterion (Harman 1976). quartimax maximizes the variance of the squared loadings within the variables (rows of A). For orthogonal rotations, quartimax is equivalent to cf(0) and to oblimax.

equamax指定正交的equamax旋转. equamax最大化的加权和 varimaxquartimax准则,反映了对变量( A 行)和因素( A 列)中简单结构的关注. equamax等效于oblimin(p/2)cf(#),其中#= f/(​​2p).

equamax specifies the orthogonal equamax rotation. equamax maximizes a weighted sum of the varimax and quartimax criteria, reflecting a concern for simple structure within variables (rows of A) as well as within factors (columns of A). equamax is equivalent to oblimin(p/2) and cf(#), where # = f /(2p).

现在cf(Crawford-Ferguson)方法也可以在 GPArotation

now the cf (Crawford-Ferguson) method is also available in GPArotation

cfT正交Crawford-Ferguson族

cfT orthogonal Crawford-Ferguson family

cfT(L, Tmat=diag(ncol(L)), kappa=0, normalize=FALSE, eps=1e-5, maxit=1000)

参数kappa为Crawford-Ferguson方法的族参数化.如果m是因子数,p是指标数,则具有特殊名称的kappa值是0 =四分数最大值,1/p = Varimax,m/(2 * p)= Equamax,(m-1)/(p + m-2)= Parsimax,1 =因子简约.

The argument kappa parameterizes the family for the Crawford-Ferguson method. If m is the number of factors and p is the number of indicators then kappa values having special names are 0=Quartimax, 1/p=Varimax, m/(2*p)=Equamax, (m-1)/(p+m-2)=Parsimax, 1=Factor parsimony.

X <- matrix(rnorm(500), ncol=10)
C <- cor(X)
eig <- eigen(C)
# PCA by hand scaled by sqrt
eig$vectors * t(matrix(rep(sqrt(eig$values), 10), ncol=10))
require(psych)
PCA0 <- principal(C, rotate='none', nfactors=10) #PCA by psych
PCA0

# as the original loadings PCA0 are scaled by their squarroot eigenvalue
apply(PCA0$loadings^2, 2, sum) # SS loadings

## PCA with Equimax rotation
# now i think the Equamax rotation can be performed by cfT with m/(2*p)
# p number of variables (10) 
# m (or f in STATA manual) number of components (10)
# gives m==p --> kappa=0.5

PCA.EQ <- cfT(PCA0$loadings, kappa=0.5)
PCA.EQ

我通过您的问题提升了PCA的一些知识,希望对您有所帮助,祝您好运

I upgraded some of my PCA knowledge by your question, hope it helps, good luck

这篇关于R中EQUAMAX旋转的主成分分析的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆