By Ruben Geert van den Berg on January 20, 2015 under SPSS Correlation Tools.

# SPSS Correlations without Significance

## Summary

SPSS CORRELATIONS generates tables containing correlations, the N for each correlation and its supposed significance. Unfortunately, there's no simple way to suppress the latter two pieces of information. This tutorial therefore proposes a simple tool for hiding the significance and/or N after the correlation tables have been produced.

## SPSS FACTOR Command

An alternative for generating correlations without significance is via SPSS FACTOR. Like so, however, you can only generate a full correlation matrix (that is, you can't use the WITH keyword).
Also, you'll have much more syntax and output than you really need. This may be especially cumbersome in case you need more than one correlation matrix. Disregarding these drawbacks, it's an option nevertheless.

## SPSS Python Syntax Example

Instead of using the Custom Dialog we just discussed, you may click here for an SPSS Python syntax version of this tool.

************1. CREATE TEST DATA.

data list free/id.
begin data
0 0 0 0 0 0 0 0 0 0 0
end data.

do repeat v = v1 to v5.
compute v = rv.bernoulli(.5).
end repeat.

************2. NO SPLIT FILE.

correlations v1 to v5.

correlations v1 with v2 to v5.

************3. ONE SPLIT FILE.

sort cases by v1.

split file by v1.

correlations v2 to v5.

correlations v2 with v3 to v5.

************4. TWO SPLIT FILES.

sort cases by v1 V2.

split file by v1 v2.

correlations v3 to v5.

correlations v3 with v4 to v5.

************5. DEFINE FUNCTION.

begin program.
def hideSignificanceCorrelations(hideSig = False,hideN = False):
import spss,SpssClient
SpssClient.StartClient()
outputDoc = SpssClient.GetDesignatedOutputDoc()
outputItems = outputDoc.GetOutputItems()
for index in range(outputItems.Size()):
outputItem = outputItems.GetItemAt(index)
if "Correlations" in outputItem.GetDescription() and outputItem.GetType() == SpssClient.OutputItemType.PIVOT:
tmpSig,tmpN = hideSig,hideN
pivotTable = outputItem.GetSpecificType()
rLabels = pivotTable.RowLabelArray()
for col in range(rLabels.GetNumColumns()):
for row in range(rLabels.GetNumRows()):
if tmpSig and not(rLabels.GetTextHiddenAt(row,col)) and ("Sig. (2-tailed)" in rLabels.GetValueAt(row,col) or "Sig. (1-tailed)" in rLabels.GetValueAt(row,col)):
rLabels.HideLabelsWithDataAt(row,col)
rLabels.SetTextHiddenAt(row,col,True)
tmpSig = False
if tmpN and not(rLabels.GetTextHiddenAt(row,col)) and rLabels.GetValueAt(row,col) == "N" :
rLabels.HideLabelsWithDataAt(row,col)
rLabels.SetTextHiddenAt(row,col,True)
tmpN = False
SpssClient.StopClient()
end program.

************6. RUN FUNCTION.

begin program.
hideSignificanceCorrelations(hideSig = True,hideN = True)
end program.

# Related Tutorials

## Correlation Coefficient – What Is It?

Correlation coefficients explained in normal language with illustrations and examples. Read more

## SPSS Correlation Test

Summary SPSS CORRELATIONS generates tables containing correlations, the N for each correlation and its supposed significance. Unfortunately, there's no simple way to suppress the latter two pieces of information. This tutorial therefore proposes a simple tool for hiding the significance and/or N after the correlation tables have been produced. Hiding Significance for Correlation Tables First, ... (Read More) Read more

# Comment on this Tutorial

*Required field. Your comment will show up after approval from a moderator.