* Encoding: UTF-8.
* Encoding: .
*sort by ip address, to locate duplicate IPs.
*duplicates (second time ip address appears) hand coded 1.
*Recode all other observations as 0.
*filter out the duplicates.
DATASET ACTIVATE DataSet1.
USE ALL.
COMPUTE filter_$=(ExcludeDuplicateIP = 0).
VARIABLE LABELS filter_$ 'ExcludeDuplicateIP = 0 (FILTER)'.
VALUE LABELS filter_$ 0 'Not Selected' 1 'Selected'.
FORMATS filter_$ (f1.0).
FILTER BY filter_$.
EXECUTE.
*chi square analysis of DV.
CROSSTABS
/TABLES=close BY visual
/FORMAT=AVALUE TABLES
/STATISTICS=CHISQ
/CELLS=COUNT ROW
/COUNT ROUND CELL.
*next consider condition differences on formality.
*we did not preregister that we would look for outliers.
*there are no outliers if you look at the full dataset, but two outliers if you look by condition.
EXAMINE VARIABLES=formal
/PLOT BOXPLOT STEMLEAF
/COMPARE GROUPS
/STATISTICS DESCRIPTIVES
/CINTERVAL 95
/MISSING LISTWISE
/NOTOTAL.
EXAMINE VARIABLES=formal BY close
/PLOT BOXPLOT STEMLEAF
/COMPARE GROUPS
/STATISTICS DESCRIPTIVES
/CINTERVAL 95
/MISSING LISTWISE
/NOTOTAL.
*Manually create "outlier_formal" and assign value of 1 to outliers by condition.
*these two outliers both answered 3 in the distance condition.
*Recode the rest as 0.
RECODE outlier_formal (1=1) (SYSMIS=0).
EXECUTE.
*to do supplemental analysis with outliers excluded use this filter, small difference in t (8.72 here vs 8.19 without dropping outliers).
*USE ALL.
*COMPUTE filter_$=(duplicate = 0 & outlier_formal=0).
*VARIABLE LABELS filter_$ 'duplicate = 0 & outlier_formal = 0 (FILTER)'.
*VALUE LABELS filter_$ 0 'Not Selected' 1 'Selected'.
*FORMATS filter_$ (f1.0).
*FILTER BY filter_$.
*EXECUTE.
*differences by condition on formality.
T-TEST GROUPS=close(0 1)
/MISSING=ANALYSIS
/VARIABLES=formal
/CRITERIA=CI(.95).
*process macro used for mediation, model 4 (simple mediation).
*version 2.15 is used, which is appropriate for dichotomous dv.
*logisitic regression conducted for b path (cross-check with process output).
LOGISTIC REGRESSION VARIABLES visual
/METHOD=ENTER formal close
/CRITERIA=PIN(.05) POUT(.10) ITERATE(20) CUT(.5).