Last data update: 2014.03.03

R: Parallel Analysis
an.parallelR Documentation

Parallel Analysis

Description

performs Horn's parallel analysis for a principal component.

Usage

an.parallel(x = NA, iterations = 0, centile = 0, seed = 0, mat = NA,
  n = NA)

Arguments

x

a matrix or a Dataframe that holds the test response data

iterations

a number indicating the amount of iterations that representing the number of random data sets to be produced in the analysis.

centile

a number between 1 and 99 indicating the centile used in estimating bias.

seed

specifies that the random number is to be seeded with the supplied integer.

mat

specifies that the procedure use the provided correlation matrix rather than supplying a data matrix through x. The n argument must also be supplied when mat is used.

n

the number of observations. Required when the correlation matrix is supplied with the mat option.

Details

Is a implementation of Horn's (1965) tecnique for evaluating the components retained in a principle component analysis (PCA). This procedure is a adaptation of the function paran of Package Paran.

Value

Retained Components a scalar integer representing the number of components retained.

Adjusted eigenvalues a vector of the estimated eigenvalues adjusted.

Unadjusted eigenvalues a vector of the eigenvalues of the observed data from either an unrotated principal component analysis.

Bias a vector of the estimated bias of the unadjusted eigenvalues

References

John L. Horn (1965). A rationale and test for the number of factors in factor analysis. Psychometrika, Volume 30, Number 2, Page 179.

Dinno A. 2009. Exploring the Sensitivity of Horn's Parallel Analysis to the Distributional Form of Simulated Data. Multivariate Behavioral Research. 44(3): 362-388

Examples

data <- simulateTest(model="2PL",items=10,individuals=1000) 
an.parallel(data$test, iterations = 100, centile = 99, seed = 12)

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(IRTpp)
> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/IRTpp/an.parallel.Rd_%03d_medium.png", width=480, height=480)
> ### Name: an.parallel
> ### Title: Parallel Analysis
> ### Aliases: an.parallel
> 
> ### ** Examples
> 
> data <- simulateTest(model="2PL",items=10,individuals=1000) 
> an.parallel(data$test, iterations = 100, centile = 99, seed = 12)

Using eigendecomposition of correlation matrix.

Results of Horn's Parallel Analysis for component retention
100 iterations, using the 99 centile estimate

-------------------------------------------------- 
Component   Adjusted    Unadjusted    Estimated 
            Eigenvalue  Eigenvalue    Bias 
-------------------------------------------------- 
1           2.630790    2.851498      0.220707
2           0.904242    1.056722      0.152480
3           0.907721    1.022575      0.114854
4           0.892525    0.958701      0.066176
5           0.845475    0.885671      0.040196
6           0.853727    0.860941      0.007214
7           0.755071    0.735765     -0.01930
8           0.674845    0.623950     -0.05089
9           0.612095    0.536551     -0.07554
10          0.580621    0.467620     -0.11300
-------------------------------------------------- 

Adjusted eigenvalues > 1 indicate dimensions to retain.
(1 components retained)

> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>