Setup initial file structure
This commit is contained in:
23
Modules/ado/plus/p/polychoricpca.ado
Normal file
23
Modules/ado/plus/p/polychoricpca.ado
Normal file
@ -0,0 +1,23 @@
|
||||
*! Principal component analysis based on polychoric correlations
|
||||
*! Author: Stas Kolenikov, skolenik@unc.edu. Version 1.0
|
||||
|
||||
program define polychoricpca, rclass
|
||||
|
||||
syntax varlist(numeric min=2) [aw pw fw /], [SCore(passthru) NSCore(passthru) nolog *]
|
||||
|
||||
if "`score'"!="" & "`nscore'"=="" {
|
||||
di as err "how many score variables?"
|
||||
exit 198
|
||||
}
|
||||
|
||||
if "`exp'"=="" {
|
||||
tempvar ww
|
||||
qui g byte `ww'=1
|
||||
local exp `ww'
|
||||
local weight pw
|
||||
}
|
||||
|
||||
polychoric `varlist' [`weight'=`exp'] , pca nolog `score' `nscore' `options'
|
||||
return add
|
||||
|
||||
end
|
Reference in New Issue
Block a user