search for: polychoric

Displaying 20 results from an estimated 59 matches for "polychoric".

2012 Dec 07
1
Polychor() - why does it take that long?
Hello. Using the polychor function > polychor(data[c(s1,s2)] ) for polychoric correlations of two ordinal variables in R takes a long time for N=7000 (20 minutes+) and significantly slows down my computer. Now, I have a pretty old computer, but it takes about 20 seconds for MPLUS to print out the complete polychoric correlation matrix for all 16 variables, while I am runnin...
2009 Jan 12
3
polychoric correlation: issue with coefficient sign
Hello, I am running polychoric correlations on a dataset composed of 12 ordinal and binary variables (N =384), using the polycor package. One of the association (between 2 dichotomous variables) is very high using the 2-step estimate (0.933 when polychoric run only between the two variables; but 0.801 when polychoric run on the...
2007 Dec 19
1
Correlation when one variable has zero variance (polychoric?)
...simulation study, so many combinations of parameter produce many predictions that I need to correlate with data. The problem ---------------- I'm using rating data with 3 to 5 categories (e.g., too low, correct, too high). The underlying continuous scales should be normal, so I chose the polychoric correlation. I'm using library(polychor) in its latest version 0.7.4 The problem is that sometimes the models predict always the same value (i.e., the median). Example frequency table: > table(med$ADRI_LAN, rate$ADRI_LAN) 2 3 4 5 3 28 179 141 50 That is, there is no...
2004 Nov 28
2
Tetrachoric and polychoric ceofficients (for sem) - any tips?
...suggested that at that time nobody had these coefficients ready to go. (a) has anyone in the meanwhile programmed them? (b) I think I can see how to do the tetrachoric one with mvtnorm on similar lines to an example on the help page so will try that if nobody else already has (c) looking at the polychoric one makes me realise yet again that I wish I knew more mathematics. I would also find it difficult to test it as I do not have any worked examples. Does anyone have any tips about how to program it and how to test the resultant code? (d) I appreciate this last item is not strictly an R question,...
2006 Aug 21
2
polychor error
Hi. Does anyone know whether the following error is a result of a bug or a feature? I can eliminate the error by making ML=F, but I would like to see the values of the cut-points and their variance. tmp.vec<-c(0, 0, 0 , 0 ,0 , 1, 0, 2, 0 , 0, 5 ,5 ,3 ,1, 0 , 1, 5, 10, 27, 20, 9, 0, 1, 1, 12, 29, 57, 34, 0, 0, 1, 2, 11, 31, 32) tmp.mat<-matrix(tmp.vec, nrow=7)
2006 Oct 19
2
How to get multiple Correlation Coefficients
Hi I have used a polycor package for categorical correlation coefficients. I run the following script. But there were no results. Could you tell me how to correct the script? Thanks in advance, vars <- names(sdi) for (i in 1:length(vars)) { for (j in 1:length(vars)) { paste(vars[i]," and ", vars[j]) polychor(vars[i], vars[j]) # corr } } -- Kum-Hoe Hwang, Ph.D.Phone :
2013 Dec 17
1
Polychoric Principal Component Analysis (pPCA)
I have data set with binary responses. I would like to conduct polychoric principal component analysis (pPCA). I know there are several packages used in PCA but I could not find one that directly estimate pPCA and graph the individuals and variables maps. I will appreciate any help that expand these reproducible scripts. #How to conduct polychoric principal component ana...
2006 Aug 04
1
polychoric correlation error
Dear all, I get a strange error when I find polychoric correlations with the ML method, which I have been able to reproduce using randomly-generated data. What is wrong? I realize that the data that I generated randomly is a bit strange, but it is the only way that I duplicate the error message. > n<-100 > test.x<-rnorm(n, mean=0, sd=1...
2004 Dec 09
1
Re: Tetrachoric and polychoric correlations, Polycor package
A bit late, but you might like to look at http://www.qimr.edu.au/davidD/polyr.R Regarding the original posters queries: You can analyse polychoric correlations as if they were Pearson correlations using standard software (eg sem), and this usually doesn't do too badly, or go to AWLS (Browne) in LISREL etc, or ML analysis of the full multidimensional contingency table using programs such as Mx, or as you noted, mvtnorm (Mx uses Alan Genz...
2008 Sep 01
1
Polychoric and tetrachoric correlation
Hi there, Am I correct to believe that tetrachoric correlation is a special case of polychoric correlation when there are only two levels to the ordered factor? Thus it should be okay to use hetcor from the polycor package to build a matrix of correlations for binary variables? If this is true, how can one estimate 95% confidence intervals for the correlations? My guess would be ma...
2008 May 07
0
p values for polychor
hello, i have been using cor.test() for calculating the correlation coefficient and p values for some data. however, since the data consist of two dichotomous sequences (actually just binary data), i understand that simply using the pearson correlation is not sufficient. however, having done a bit of research i found that the tetrachoric correlation is what i am after. found the polycor package
2010 Apr 02
2
tetrachoric correlations
Hi, Is there any R library/package that calculates tetrachoric correlations from given marginals and Pearson correlations among ordinal variables? Inputs to polychor function in polycor package are either contingency tables or ordinal data themselves. I am looking for something that takes marginal distributions and Pearson correlation as inputs. For example, Y1=(1,2,3) with P(Y1=1)=0.3,
2012 Oct 02
0
Error messages when attempting to calculate polychoric correlation matrices using the psych package
Dear Professor Fox, Apologies for my oversight relating to the polychor command and thank you for your advice. I turned to the polychor command when trying to find an equivalent for the polychoric command found in the psych package (I am following a procedure outlined in Gadermann, Guhn & Zumbo, 2012 that uses this command rather than the polycor package) . The polychoric command is returning an error: > polychoric(data.matrix18) Error in max(x, na.rm = TRUE) - min(x, na.rm = TRUE) :...
2013 Nov 28
0
polychoric correlation with multiple imputations, a Strate and a Weight
...9;m generally more a Stata user than a R user, but I need to computed something, and I am not able to do it with Stata 13. So, here I am! I have a database that has multiple imputations (imputations are already done) with a complex sample design (Strate and Weight). Is it possible, in R, to run polychoric correlation with multiple imputation, a Strate and a Weight ? For the moment, I have been able to do some statistical analysis with Strate and Weight using the Survey package. I also know that there is a package named Amelia II that can handle multiple imputations, and polycor that can compute pol...
2009 Mar 11
2
non-positive definite matrix remedies?
Hi all, For computational reasons, I need to estimate an 18x18 polychoric correlation matrix two variables at a time (rather than trying to estimate them all simultaneously using ML). The resulting polychoric correlation matrix I am getting is non-positive definite, which is problematic because I'm using this matrix later on as if it were a legitimately estimated cor...
2004 Dec 09
0
Re: Polychoric correlations
...structural > equation models. If anyone thinks that is misguided I would be intersted to > here. > > Michael Dewey > m.dewey at iop.kcl.ac.uk As you might know, there are various ways you can fit what in the genetic literature is called a multifactorial threshold model (MFT ie tetra/polychoric correlation model). The simplest is to treat them as Pearson correlations and use conventional SEM methods, which often works well (esp for large dimensional problems); the AWLS method of Browne as implemented for example in LISREL (needs large N); or full ML fitting to the multidimensional contin...
2012 Oct 01
1
Error messages when attempting to calculate polychoric correlation matrices
Dear R users, I am a psychology postgraduate student who is relatively new to using R. I am currently developing a psychometric scale and have run into a few problems when using R to calculate a polychoric correlation matrix for my dataset. I am trying to produce a polychoric correlation matrix for calculating ordinal reliability estimates (eg. Alpha, omega).The set consists of 439 observations of 18 variables. Each of the 18 variables was measured using a 6 point Likert scale but some variables only...
2007 Jul 13
2
nearest correlation to polychoric
...eone implemented in R (or any other language) Knol DL, ten Berge JMF. Least-squares approximation of an improper correlation matrix by a proper one. Psychometrika, 1989, 54, 53-61. or any other similar algorithm? Best regards Jens Oehlschl?gel Background: I want to factanal() matrices of polychoric correlations which have negative eigenvalue. I coded Highham 2002 Computing the nearest correlation matrix - a problem from finance, IMA Journal of Numerical Analysis (2002), 22, 329-343. which basically works but still leaves very small negative eigenvalues which causes factanal() to fail with...
2012 Jan 24
0
PCA for assets based household income analysis (" hetcor" and "princomp")
...doing Principal Component Analysis (PCA) on assets data for household income prediction. The problem is that the assets data are rank ordered (usually binary ... possess car/don't possess car), so the normal correlation is inappropriate for the calculation of the PCA. Instead one has to use the polychoric correlation coefficient. It uses the "random.polychor.pa" package. Scenario 1 If i only use PCA without using&nbsp;polychoric correlation assets.pca &lt;- princomp(covmat = assets, scores=T) assets$income&lt;-predict(assets2.pca)[,1] # these predict the&nbsp;coefficien...
2009 Feb 02
1
Fit indexes in SEM with categorical data + ML estimation
Hello, It has been found that SEM analysis using polychoric correlations + maximum likelihood estimator produces incorrect test statistics and standard errors (e.g., Flora, D. B., & Curran, P. J. (2004). An Empirical Evaluation of Alternative Methods of Estimation for Con?rmatory Factor Analysis With Ordinal Data. Psychological Methods, 9(4), 466-491)....