Skip to content
Prev 256652 / 398506 Next

How to calculate KMO?

Dear Thibault,

On Tue, Apr 12, 2011 at 5:06 PM, Thibault Grava
<tybo.tout.seul at gmail.com> wrote:
Please forgive me, but I'm not sure I really understand what your
question is.  My advice would be to go here:

https://stat.ethz.ch/pipermail/r-help/2007-August/138049.html

and copy-paste the function listed there - it looks like

kmo = function( data ){

...bunch of stuff here...

} # end of kmo()

into an R session, for instance, on the Windows RGui.  If you like,
you can test that everything works with the example shown right below
that (just copy-paste, again).  You don't need any corpcor package,
all you need is MASS which should have shipped with the R you are
using.

You also don't need a data directory.  What you need is a matrix
(called "X" in my message) with the data stored in the correct
order/positions.  See the Trujillo-Ortiz et al. discussion (linked in
my message) for lots more detail about what the matrix means and how
to set it up.  If you are having trouble setting up a data matrix in
general then I recommend the R documentation which you can find under
the Help menu.

I just double-checked and both the function and example still work
like a charm, almost 4 years later. (?!)

Good luck, and I hope this helps.
Jay


______________________________
G. Jay Kerns, Ph.D.
Youngstown State University
http://people.ysu.edu/~gkerns/