Reputation: 13
I have 5 samples with n=10 observations each, I can make a variance-covariance matrix in graphs in SPSS program but I can't figure out how to make this matrix with numbers. Can someone please help me with the steps?
Upvotes: 1
Views: 6626
Reputation: 160
If you are looking to generate a covariance matrix in SPSS, there are a couple paths to do this.
Point-and-Click Method
Analyze -> Correlate -> Bivariate...
Add the list of variables for which you want to create a covariance matrix to the "Variables" box. Then click "Options...". Tick the box for "Cross-product deviations and covariances." Then Continue, then OK.
Your output will have the covariance matrix embedded within SPSS's output window. If you use the pivot trays functionality from the output window (double click on the output and switch the Statistics and Variables next to where it says "Row"), you can get a relatively clean covariance matrix.
Syntax
Here is some sample syntax:
CORRELATIONS
/VARIABLES=v1 v2 v3 v4 v5
/PRINT=TWOTAIL NOSIG
/STATISTICS XPROD *This line gets the covariance matrix.
/MISSING=PAIRWISE.
That will produce the same output as the point-and-click method. You'll need to follow the same process to edit the output to a more usable form.
Upvotes: 1