Published on :
Statistical CREATION_INTERNE

Factor Analysis with COSAN Model and Constraints (PROC CALIS)

This code is also available in: Deutsch Español Français
Awaiting validation
This script uses the CALIS procedure to analyze a correlation matrix (Kinzer & Kinzer data, Guttman 1957). It defines a COSAN type model by explicitly specifying parameter matrices (D, B, Psi) and applies complex algebraic constraints on factor loadings and correlation structures using built-in SAS© programming statements.
Data Analysis

Type : CREATION_INTERNE


The data is a correlation matrix (TYPE=CORR) created directly in the script via a DATA STEP and datalines.

1 Code Block
DATA STEP Data
Explanation :
Creation of the 'kinzer' dataset containing the lower triangular correlation matrix for 6 variables.
Copied!
1DATA kinzer(type=corr);
2title "Data Matrix of Kinzer & Kinzer, see GUTTMAN (1957)";
3 _type_ = 'corr';
4 INPUT _name_ $ var1-var6;
5 DATALINES;
6var1 1.00 . . . . .
7var2 .51 1.00 . . . .
8var3 .46 .51 1.00 . . .
9var4 .46 .47 .54 1.00 . .
10var5 .40 .39 .49 .57 1.00 .
11var6 .33 .39 .47 .45 .56 1.00
12;
2 Code Block
PROC CALIS
Explanation :
Execution of the CALIS procedure with the COSAN statement. Definition of the model structure, parameter matrices (B, Psi, D) and application of specific mathematical constraints on the coefficients via standard SAS code within the procedure.
Copied!
1PROC CALIS DATA=Kinzer nobs=326 nose;
2 cosan
3 var= var1-var6,
4 D(6,DIA) * B(2,GEN) + D(6,DIA) * Psi(6,DIA);
5 matrix B
6 [ ,1] = b11 b21 b31 b41 b51 b61,
7 [ ,2] = b12 b22 b32 b42 b52 b62;
8 matrix Psi
9 [1,1] = psi1-psi6;
10 matrix D
11 [1,1] = d1-d6;
12 parameters alpha (1.);
13 
14 /* SAS Programming Statements to Define Dependent Parameters*/
15 /* 6 constraints on the factor loadings */
16 b12 = alpha - b11;
17 b22 = alpha - b21;
18 b32 = alpha - b31;
19 b42 = alpha - b41;
20 b52 = alpha - b51;
21 b62 = alpha - b61;
22 
23 /* 6 Constraints on Correlation structures */
24 psi1 = 1. - b11 * b11 - b12 * b12;
25 psi2 = 1. - b21 * b21 - b22 * b22;
26 psi3 = 1. - b31 * b31 - b32 * b32;
27 psi4 = 1. - b41 * b41 - b42 * b42;
28 psi5 = 1. - b51 * b51 - b52 * b52;
29 psi6 = 1. - b61 * b61 - b62 * b62;
30 vnames
31 D = [var1-var6],
32 B = [factor1 factor2],
33 Psi = D;
34RUN;
This material is provided "as is" by We Are Cas. There are no warranties, expressed or implied, as to merchantability or fitness for a particular purpose regarding the materials or code contained herein. We Are Cas is not responsible for errors in this material as it now exists or will exist, nor does We Are Cas provide technical support for it.
Copyright Info : SAS SAMPLE LIBRARY