The homework aims to explore the factors that influence experiences in close relationships. A survey was conducted using 36 statements designed to measure different aspects of relationship experiences. Participants were asked to rate their level of agreement with each statement on a 5-point Likert scale, ranging from “Strongly Disagree” to “Strongly Agree.” The data was collected from 1,000 randomly selected individuals. The goal of the analysis is to identify the most important factors that shape experiences in close relationships using factor analysis.

mydata <- read.table("./data.csv", header=TRUE, sep=",", dec=".")
head(mydata)
##   Q1 Q2 Q3 Q4 Q5 Q6 Q7 Q8 Q9 Q10 Q11 Q12 Q13 Q14 Q15 Q16 Q17 Q18 Q19 Q20 Q21
## 1  1  5  5  5  1  5  1  5  1   5   1   5   1   2   5   5   1   5   4   5   1
## 2  1  1  5  1  1  1  1  1  1   1   1   5   1   1   5   5   1   1   5   5   1
## 3  1  5  5  5  3  5  1  5  1   5   2   3   1   5   4   4   3   5   5   2   2
## 4  4  5  1  4  5  5  5  1  1   3   4   4   4   4   2   4   4   3   4   2   5
## 5  4  5  3  4  4  4  3  4  2   2   4   2   3   4   4   3   2   4   4   4   3
## 6  4  2  3  3  5  3  4  3  5   3   5   1   5   2   2   2   5   1   2   1   5
##   Q22 Q23 Q24 Q25 Q26 Q27 Q28 Q29 Q30 Q31 Q32 Q33 Q34 Q35 Q36 age gender
## 1   1   1   5   5   5   5   4   5   5   5   5   5   5   5   5  32      2
## 2   5   1   1   5   1   5   1   5   5   5   5   5   1   5   5  35      1
## 3   1   1   3   2   2   4   2   3   4   4   4   4   4   3   2  19      1
## 4   2   4   4   5   3   4   4   2   3   2   4   4   5   4   3  32      1
## 5   2   2   5   4   3   4   5   4   5   4   4   5   5   5   4  27      1
## 6   4   5   3   2   1   4   3   1   5   5   5   5   3   4   2  18      1
##   country
## 1      US
## 2      US
## 3      IL
## 4      US
## 5      IE
## 6      IT
•   Q1: I prefer not to show a partner how I feel deep down.
•   Q2: I worry about being abandoned.
•   Q3: I am very comfortable being close to romantic partners.
•   Q4: I worry a lot about my relationships.
•   Q5: Just when my partner starts to get close to me I find myself pulling away.
•   Q6: I worry that romantic partners won’t care about me as much as I care about them.
•   Q7: I get uncomfortable when a romantic partner wants to be very close.
•   Q8: I worry a fair amount about losing my partner.
•   Q9: I don’t feel comfortable opening up to romantic partners.
•   Q10: I often wish that my partner’s feelings for me were as strong as my feelings for him/her.
•   Q11: I want to get close to my partner, but I keep pulling back.
•   Q12: I often want to merge completely with romantic partners, and this sometimes scares them away.
•   Q13: I am nervous when partners get too close to me.
•   Q14: I worry about being alone.
•   Q15: I feel comfortable sharing my private thoughts and feelings with my partner.
•   Q16: My desire to be very close sometimes scares people away.
•   Q17: I try to avoid getting too close to my partner.
•   Q18: I need a lot of reassurance that I am loved by my partner.
•   Q19: I find it relatively easy to get close to my partner.
•   Q20: Sometimes I feel that I force my partners to show more feeling, more commitment.
•   Q21: I find it difficult to allow myself to depend on romantic partners.
•   Q22: I do not often worry about being abandoned.
•   Q23: I prefer not to be too close to romantic partners.
•   Q24: If I can’t get my partner to show interest in me, I get upset or angry.
•   Q25: I tell my partner just about everything.
•   Q26: I find that my partner(s) don’t want to get as close as I would like.
•   Q27: I usually discuss my problems and concerns with my partner.
•   Q28: When I’m not involved in a relationship, I feel somewhat anxious and insecure.
•   Q29: I feel comfortable depending on romantic partners.
•   Q30: I get frustrated when my partner is not around as much as I would like.
•   Q31: I don’t mind asking romantic partners for comfort, advice, or help.
•   Q32: I get frustrated if romantic partners are not available when I need them.
•   Q33: It helps to turn to my romantic partner in times of need.
•   Q34: When romantic partners disapprove of me, I feel really bad about myself.
•   Q35: I turn to my partner for many things, including comfort and reassurance.
•   Q36: I resent it when my partner spends time away from me.
• age.
• gender: (1:M, 2:F)
• country

Source: https://www.kaggle.com/datasets/mathurinache/experiences-in-close-relationship-scale

mydata <- mydata[, -c(37, 38, 39)]

Research Question:

What are the factors that influence experiences in close relationships?

library(pastecs)
round(stat.desc(mydata, basic = FALSE), 2)
##                Q1   Q2   Q3   Q4   Q5   Q6   Q7   Q8   Q9  Q10  Q11  Q12  Q13
## median       2.00 4.00 4.00 4.00 2.00 4.00 2.00 3.00 2.00 3.00 3.00 2.00 2.00
## mean         2.72 3.60 3.61 3.40 2.75 3.54 2.58 3.25 2.66 3.30 2.79 2.47 2.62
## SE.mean      0.04 0.04 0.04 0.04 0.04 0.04 0.04 0.04 0.04 0.04 0.04 0.04 0.04
## CI.mean.0.95 0.08 0.08 0.08 0.08 0.08 0.08 0.08 0.08 0.08 0.08 0.08 0.08 0.08
## var          1.67 1.67 1.63 1.59 1.79 1.68 1.76 1.64 1.63 1.65 1.74 1.60 1.64
## std.dev      1.29 1.29 1.28 1.26 1.34 1.30 1.33 1.28 1.28 1.29 1.32 1.27 1.28
## coef.var     0.48 0.36 0.35 0.37 0.49 0.37 0.51 0.39 0.48 0.39 0.47 0.51 0.49
##               Q14  Q15  Q16  Q17  Q18  Q19  Q20  Q21  Q22  Q23  Q24  Q25  Q26
## median       4.00 4.00 2.00 2.00 4.00 4.00 3.00 3.00 2.00 2.00 3.00 4.00 2.00
## mean         3.26 3.42 2.44 2.60 3.35 3.25 2.75 3.24 2.69 2.38 3.10 3.27 2.63
## SE.mean      0.05 0.04 0.04 0.04 0.04 0.04 0.04 0.04 0.04 0.04 0.04 0.04 0.04
## CI.mean.0.95 0.09 0.08 0.08 0.08 0.08 0.08 0.08 0.08 0.08 0.07 0.08 0.08 0.07
## var          2.04 1.74 1.55 1.50 1.77 1.47 1.73 1.79 1.77 1.38 1.71 1.69 1.37
## std.dev      1.43 1.32 1.24 1.22 1.33 1.21 1.32 1.34 1.33 1.18 1.31 1.30 1.17
## coef.var     0.44 0.39 0.51 0.47 0.40 0.37 0.48 0.41 0.50 0.49 0.42 0.40 0.45
##               Q27  Q28  Q29  Q30  Q31  Q32  Q33  Q34  Q35  Q36
## median       4.00 2.00 3.00 3.00 4.00 4.00 4.00 4.00 4.00 2.00
## mean         3.61 2.66 2.94 3.16 3.64 3.26 3.76 3.60 3.65 2.53
## SE.mean      0.04 0.04 0.04 0.04 0.04 0.04 0.03 0.04 0.04 0.04
## CI.mean.0.95 0.07 0.09 0.08 0.08 0.07 0.08 0.07 0.08 0.07 0.08
## var          1.28 1.93 1.54 1.62 1.41 1.53 1.21 1.62 1.29 1.57
## std.dev      1.13 1.39 1.24 1.27 1.19 1.24 1.10 1.27 1.14 1.25
## coef.var     0.31 0.52 0.42 0.40 0.33 0.38 0.29 0.35 0.31 0.50
mydata_FA <- mydata
R <- cor(mydata_FA)

library(psych) 
corPlot(R)

library(psych)
cortest.bartlett(R, n=nrow(mydata))
## $chisq
## [1] 19738.39
## 
## $p.value
## [1] 0
## 
## $df
## [1] 630
library(psych)
KMO(R)
## Kaiser-Meyer-Olkin factor adequacy
## Call: KMO(r = R)
## Overall MSA =  0.94
## MSA for each item = 
##   Q1   Q2   Q3   Q4   Q5   Q6   Q7   Q8   Q9  Q10  Q11  Q12  Q13  Q14  Q15  Q16 
## 0.95 0.92 0.97 0.96 0.93 0.94 0.95 0.94 0.96 0.92 0.93 0.91 0.95 0.94 0.96 0.90 
##  Q17  Q18  Q19  Q20  Q21  Q22  Q23  Q24  Q25  Q26  Q27  Q28  Q29  Q30  Q31  Q32 
## 0.95 0.96 0.96 0.96 0.94 0.93 0.95 0.95 0.94 0.94 0.95 0.94 0.93 0.93 0.94 0.92 
##  Q33  Q34  Q35  Q36 
## 0.94 0.96 0.94 0.94
det(R)
## [1] 2.029926e-09
fa.parallel(mydata_FA,
            sim = FALSE,
            fa = "fa")

## Parallel analysis suggests that the number of factors =  6  and the number of components =  NA
library(psych)
library(GPArotation)
## 
## Attaching package: 'GPArotation'
## The following objects are masked from 'package:psych':
## 
##     equamax, varimin
factors <- fa(mydata_FA, 
              covar = FALSE, 
              fm = "minres",
              nfactors = 6, 
              rotate = "oblimin", 
              impute = "mean") 

print.psych(factors, 
            cut = 0.3, 
            sort = TRUE)
## Factor Analysis using method =  minres
## Call: fa(r = mydata_FA, nfactors = 6, rotate = "oblimin", covar = FALSE, 
##     impute = "mean", fm = "minres")
## Standardized loadings (pattern matrix) based upon correlation matrix
##     item   MR1   MR3   MR2   MR4   MR5   MR6   h2   u2 com
## Q13   13  0.87                               0.68 0.32 1.0
## Q5     5  0.79                               0.66 0.34 1.0
## Q7     7  0.79                               0.62 0.38 1.0
## Q11   11  0.75                               0.60 0.40 1.1
## Q17   17  0.71                               0.61 0.39 1.1
## Q23   23  0.68                               0.61 0.39 1.4
## Q21   21  0.55                               0.37 0.63 1.3
## Q9     9  0.50 -0.36                         0.60 0.40 2.0
## Q3     3 -0.47                               0.46 0.54 1.8
## Q1     1  0.40 -0.35                         0.46 0.54 2.4
## Q27   27        0.79                         0.57 0.43 1.0
## Q25   25        0.73                         0.59 0.41 1.1
## Q33   33        0.72                         0.57 0.43 1.1
## Q31   31        0.72                         0.55 0.45 1.0
## Q35   35        0.65                         0.57 0.43 1.2
## Q15   15        0.61                         0.48 0.52 1.1
## Q19   19 -0.30  0.44                         0.45 0.55 2.1
## Q29   29        0.34                         0.35 0.65 2.7
## Q2     2              0.80                   0.64 0.36 1.0
## Q8     8              0.79                   0.66 0.34 1.1
## Q22   22             -0.73                   0.51 0.49 1.2
## Q14   14              0.61                   0.56 0.44 1.5
## Q4     4              0.59                   0.54 0.46 1.3
## Q6     6              0.58                   0.59 0.41 1.6
## Q34   34              0.42                   0.31 0.69 1.7
## Q18   18              0.37  0.34             0.53 0.47 2.5
## Q32   32                    0.80             0.61 0.39 1.0
## Q30   30                    0.74             0.64 0.36 1.1
## Q36   36                    0.63             0.45 0.55 1.1
## Q24   24                    0.59             0.55 0.45 1.2
## Q16   16                          0.85       0.68 0.32 1.0
## Q12   12                          0.75       0.58 0.42 1.0
## Q26   26                          0.54       0.54 0.46 1.5
## Q20   20                    0.31  0.32       0.46 0.54 2.9
## Q10   10              0.40              0.40 0.62 0.38 2.8
## Q28   28                                     0.40 0.60 4.0
## 
##                        MR1  MR3  MR2  MR4  MR5  MR6
## SS loadings           5.20 4.33 4.07 2.96 2.48 0.66
## Proportion Var        0.14 0.12 0.11 0.08 0.07 0.02
## Cumulative Var        0.14 0.26 0.38 0.46 0.53 0.55
## Proportion Explained  0.26 0.22 0.21 0.15 0.13 0.03
## Cumulative Proportion 0.26 0.48 0.69 0.84 0.97 1.00
## 
##  With factor correlations of 
##       MR1   MR3  MR2   MR4   MR5   MR6
## MR1  1.00 -0.57 0.14 -0.06 -0.12  0.11
## MR3 -0.57  1.00 0.03  0.27  0.25 -0.10
## MR2  0.14  0.03 1.00  0.50  0.50  0.13
## MR4 -0.06  0.27 0.50  1.00  0.50  0.08
## MR5 -0.12  0.25 0.50  0.50  1.00  0.19
## MR6  0.11 -0.10 0.13  0.08  0.19  1.00
## 
## Mean item complexity =  1.5
## Test of the hypothesis that 6 factors are sufficient.
## 
## df null model =  630  with the objective function =  20.02 with Chi Square =  19738.39
## df of  the model are 429  and the objective function was  1.39 
## 
## The root mean square of the residuals (RMSR) is  0.02 
## The df corrected root mean square of the residuals is  0.03 
## 
## The harmonic n.obs is  1000 with the empirical chi square  623.85  with prob <  2.2e-09 
## The total n.obs was  1000  with Likelihood Chi Square =  1364.72  with prob <  5.1e-98 
## 
## Tucker Lewis Index of factoring reliability =  0.928
## RMSEA index =  0.047  and the 90 % confidence intervals are  0.044 0.05
## BIC =  -1598.7
## Fit based upon off diagonal values = 0.99
## Measures of factor score adequacy             
##                                                    MR1  MR3  MR2  MR4  MR5  MR6
## Correlation of (regression) scores with factors   0.96 0.95 0.95 0.93 0.92 0.76
## Multiple R square of scores with factors          0.93 0.90 0.90 0.86 0.85 0.58
## Minimum correlation of possible factor scores     0.85 0.80 0.80 0.72 0.70 0.15
mydata_FA <- mydata[ , !colnames(mydata) %in% c("Q28", "Q20", "Q10", "Q18", "Q1", "Q9", "Q19" , "Q29")]
fa.parallel(mydata_FA,
            sim = FALSE,
            fa = "fa")

## Parallel analysis suggests that the number of factors =  5  and the number of components =  NA
library(psych)
library(GPArotation)
factors <- fa(mydata_FA, 
              covar = FALSE, 
              fm = "minres",
              nfactors = 5, 
              rotate = "oblimin", 
              impute = "mean") 

print.psych(factors, 
            cut = 0.3, 
            sort = TRUE)
## Factor Analysis using method =  minres
## Call: fa(r = mydata_FA, nfactors = 5, rotate = "oblimin", covar = FALSE, 
##     impute = "mean", fm = "minres")
## Standardized loadings (pattern matrix) based upon correlation matrix
##     item   MR1   MR2   MR3   MR4   MR5   h2   u2 com
## Q13   10  0.86                         0.69 0.31 1.0
## Q5     4  0.79                         0.67 0.33 1.0
## Q7     6  0.77                         0.61 0.39 1.0
## Q11    8  0.74                         0.59 0.41 1.1
## Q17   14  0.71                         0.61 0.39 1.1
## Q23   17  0.69                         0.61 0.39 1.3
## Q21   15  0.56                         0.34 0.66 1.0
## Q3     2 -0.47                         0.44 0.56 1.7
## Q2     1        0.82                   0.67 0.33 1.0
## Q8     7        0.78                   0.64 0.36 1.0
## Q22   16       -0.74                   0.52 0.48 1.2
## Q14   11        0.60                   0.49 0.51 1.1
## Q4     3        0.59                   0.54 0.46 1.3
## Q6     5        0.55                   0.51 0.49 1.4
## Q34   26        0.43                   0.30 0.70 1.5
## Q27   21              0.79             0.58 0.42 1.0
## Q33   25              0.73             0.57 0.43 1.0
## Q31   23              0.71             0.55 0.45 1.0
## Q25   19              0.70             0.57 0.43 1.1
## Q35   27              0.67             0.59 0.41 1.2
## Q15   12              0.58             0.46 0.54 1.1
## Q32   24                    0.81       0.64 0.36 1.0
## Q30   22                    0.76       0.66 0.34 1.0
## Q36   28                    0.63       0.45 0.55 1.1
## Q24   18                    0.56       0.52 0.48 1.3
## Q16   13                          0.83 0.69 0.31 1.0
## Q12    9                          0.75 0.60 0.40 1.0
## Q26   20                          0.55 0.48 0.52 1.3
## 
##                        MR1  MR2  MR3  MR4  MR5
## SS loadings           4.36 3.48 3.42 2.35 1.98
## Proportion Var        0.16 0.12 0.12 0.08 0.07
## Cumulative Var        0.16 0.28 0.40 0.49 0.56
## Proportion Explained  0.28 0.22 0.22 0.15 0.13
## Cumulative Proportion 0.28 0.50 0.72 0.87 1.00
## 
##  With factor correlations of 
##       MR1  MR2   MR3   MR4   MR5
## MR1  1.00 0.14 -0.55 -0.09 -0.11
## MR2  0.14 1.00  0.05  0.48  0.48
## MR3 -0.55 0.05  1.00  0.32  0.25
## MR4 -0.09 0.48  0.32  1.00  0.48
## MR5 -0.11 0.48  0.25  0.48  1.00
## 
## Mean item complexity =  1.1
## Test of the hypothesis that 5 factors are sufficient.
## 
## df null model =  378  with the objective function =  14.77 with Chi Square =  14603.18
## df of  the model are 248  and the objective function was  0.76 
## 
## The root mean square of the residuals (RMSR) is  0.02 
## The df corrected root mean square of the residuals is  0.02 
## 
## The harmonic n.obs is  1000 with the empirical chi square  302.68  with prob <  0.01 
## The total n.obs was  1000  with Likelihood Chi Square =  752.02  with prob <  3.4e-52 
## 
## Tucker Lewis Index of factoring reliability =  0.946
## RMSEA index =  0.045  and the 90 % confidence intervals are  0.041 0.049
## BIC =  -961.1
## Fit based upon off diagonal values = 1
## Measures of factor score adequacy             
##                                                    MR1  MR2  MR3  MR4  MR5
## Correlation of (regression) scores with factors   0.96 0.94 0.94 0.92 0.91
## Multiple R square of scores with factors          0.92 0.89 0.89 0.85 0.84
## Minimum correlation of possible factor scores     0.84 0.78 0.77 0.70 0.67

Q13: I am nervous when partners get too close to me. Q5: Just when my partner starts to get close to me, I find myself pulling away. Q7: I get uncomfortable when a romantic partner wants to be very close. Q11: I want to get close to my partner, but I keep pulling back. Q17: My desire to be very close sometimes scares people away. Q23: I prefer not to be too close to romantic partners. Q21: I find it difficult to allow myself to depend on romantic partners. Q3: I am very comfortable being close to romantic partners. Q2: I worry about being abandoned. Q8: I worry a fair amount about losing my partner. Q22: I do not often worry about being abandoned. Q14: I worry about being alone. Q4: I worry a lot about my relationships. Q6: I worry that romantic partners won’t care about me as much as I care about them. Q34: When romantic partners disapprove of me, I feel really bad about myself. Q27: I usually discuss my problems and concerns with my partner. Q33: It helps to turn to my romantic partner in times of need. Q31: I don’t mind asking romantic partners for comfort, advice, or help. Q25: I tell my partner just about everything. Q35: I turn to my partner for many things, including comfort and reassurance. Q15: I feel comfortable sharing my private thoughts and feelings with my partner. Q32: I get frustrated if romantic partners are not available when I need them. Q30: I get frustrated when my partner is not around as much as I would like. Q36: I resent it when my partner spends time away from me. Q24: If I can’t get my partner to show interest in me, I get upset or angry. Q16: I try to avoid getting too close to my partner. Q12: I often want to merge completely with romantic partners, and this sometimes scares them away.

1.  F1 -> Q13–Q3: Avoidance of Closeness

2.  F2 -> Q2–Q34: Anxiety in Relationships

3.  F3 -> Q27–Q15: Emotional Support

4.  F4 -> Q32–Q24: Frustration

5.  F5 -> Q16–Q26: Fear of Overdependence
fa.diagram(factors)

ResidualMatrix <- factors$residual
Residuals <- as.matrix(ResidualMatrix[upper.tri(ResidualMatrix)])
head(Residuals)
##              [,1]
## [1,] -0.012859452
## [2,] -0.018541736
## [3,]  0.020347814
## [4,]  0.007553678
## [5,]  0.007739095
## [6,]  0.007872295
HighResiduals <- abs(Residuals) > 0.05

head(HighResiduals)
##       [,1]
## [1,] FALSE
## [2,] FALSE
## [3,] FALSE
## [4,] FALSE
## [5,] FALSE
## [6,] FALSE
sum(HighResiduals)/nrow(Residuals)
## [1] 0.02645503
print(factors$weights)
##              MR1          MR2          MR3          MR4          MR5
## Q2   0.010511213  0.271807126 -0.005011581  0.006492624 -0.042048791
## Q3  -0.064862475  0.016122334  0.054214187 -0.003843821  0.017410977
## Q4   0.026808692  0.140051574  0.002644869  0.017272210  0.056890878
## Q5   0.205039342  0.016292110 -0.009034183  0.016846951 -0.029246754
## Q6   0.017559296  0.116680365 -0.008585334  0.015963318  0.083536019
## Q7   0.157062341  0.002956260  0.005703222 -0.025868636 -0.024220608
## Q8   0.011384046  0.238182696  0.014751741 -0.014634297  0.034033686
## Q11  0.135617348  0.042031421  0.002709268 -0.013986665  0.021506076
## Q12 -0.007434004  0.002283164 -0.005184729  0.006507665  0.296980886
## Q13  0.226675243  0.018415916  0.030381888 -0.026387021  0.005008014
## Q14 -0.005264532  0.130839399  0.009587393  0.027040725  0.019034693
## Q15 -0.023351491 -0.004376624  0.121466668 -0.005891275  0.018124677
## Q16 -0.004963033 -0.011237605  0.013058461 -0.006830649  0.451930313
## Q17  0.152801282 -0.002779474 -0.042053093  0.032490895  0.029384435
## Q21  0.067630149 -0.005608144 -0.004279478  0.001799837 -0.008299079
## Q22  0.025970262 -0.163142686  0.043792207 -0.005023775  0.017848966
## Q23  0.150214445 -0.066923949 -0.041052370  0.036994448 -0.011330545
## Q24  0.015273851  0.045042730 -0.005518699  0.178259798  0.050119226
## Q25 -0.011437916 -0.030785930  0.192680263 -0.007356759  0.043839550
## Q26  0.008003323  0.025388487 -0.012530373  0.051904554  0.172155326
## Q27  0.007907600 -0.015493529  0.216002268 -0.011097465  0.001170816
## Q30 -0.013716548  0.006835173  0.030565198  0.336539843  0.003788176
## Q31 -0.014798400 -0.026689922  0.180803336  0.007722940 -0.010044227
## Q32  0.006226027 -0.023605399  0.018782411  0.329241198 -0.016883741
## Q33  0.010699859  0.009180826  0.194543758  0.026916888 -0.007503618
## Q34  0.003392178  0.065465056  0.018344031  0.034120218 -0.005336652
## Q35 -0.010894560  0.042693858  0.182575544  0.054490669 -0.021896725
## Q36 -0.005198202  0.007723861 -0.022180585  0.167189551  0.028493064
head(factors$scores)
##             MR1        MR2         MR3       MR4        MR5
## [1,] -1.5533301  1.2195905  1.50651767 1.8785807  2.3800392
## [2,] -1.7727823 -2.3850747  1.62794431 0.8560867  1.1789166
## [3,] -0.7761031  1.3942420  0.01538614 0.4269966  0.8368599
## [4,]  1.7202695  0.2962311 -0.18835678 0.5556762  1.0609238
## [5,]  0.3518504  0.9992494  0.81860968 1.3715420  0.2584069
## [6,]  2.0173714 -0.9114805  0.23086347 0.9448649 -0.9741135
mydata$F1_Avoidance <- factors$scores[ , 1]
mydata$F2_Anxiety <- factors$scores[ , 2]
mydata$F3_Emotional <- factors$scores[ , 3]
mydata$F4_Frustration    <- factors$scores[ , 4]
mydata$F4_Fear    <- factors$scores[ , 5]
print(mydata[100, ])
##     Q1 Q2 Q3 Q4 Q5 Q6 Q7 Q8 Q9 Q10 Q11 Q12 Q13 Q14 Q15 Q16 Q17 Q18 Q19 Q20 Q21
## 100  3  4  2  4  4  4  4  4  4   4   4   5   4   5   4   2   3   4   2   2   4
##     Q22 Q23 Q24 Q25 Q26 Q27 Q28 Q29 Q30 Q31 Q32 Q33 Q34 Q35 Q36 F1_Avoidance
## 100   2   3   4   4   4   2   1   2   4   3   4   4   5   5   3     1.001538
##     F2_Anxiety F3_Emotional F4_Frustration   F4_Fear
## 100   0.843962  -0.05587213      0.8893779 0.7640959
F4_Fear <- mydata[, c("Q16", "Q12", "Q26")]
head(F4_Fear)
##   Q16 Q12 Q26
## 1   5   5   5
## 2   5   5   1
## 3   4   3   2
## 4   4   4   3
## 5   3   2   3
## 6   2   1   1
library(psych)
alpha(F4_Fear, 
      check.keys = TRUE)
## 
## Reliability analysis   
## Call: alpha(x = F4_Fear, check.keys = TRUE)
## 
##   raw_alpha std.alpha G6(smc) average_r S/N   ase mean sd median_r
##        0.8       0.8    0.73      0.56 3.9 0.011  2.5  1     0.54
## 
##     95% confidence boundaries 
##          lower alpha upper
## Feldt     0.77   0.8  0.82
## Duhachek  0.77   0.8  0.82
## 
##  Reliability if an item is dropped:
##     raw_alpha std.alpha G6(smc) average_r S/N alpha se var.r med.r
## Q16      0.66      0.66    0.49      0.49 1.9    0.022    NA  0.49
## Q12      0.70      0.70    0.54      0.54 2.3    0.019    NA  0.54
## Q26      0.80      0.80    0.66      0.66 4.0    0.013    NA  0.66
## 
##  Item statistics 
##        n raw.r std.r r.cor r.drop mean  sd
## Q16 1000  0.87  0.87  0.79   0.70  2.4 1.2
## Q12 1000  0.86  0.85  0.75   0.66  2.5 1.3
## Q26 1000  0.79  0.80  0.63   0.56  2.6 1.2
## 
## Non missing response frequency for each item
##        0    1    2    3    4    5 miss
## Q16 0.00 0.26 0.33 0.19 0.14 0.08    0
## Q12 0.00 0.26 0.31 0.19 0.14 0.09    0
## Q26 0.01 0.16 0.35 0.23 0.19 0.07    0

Factor analysis was done on 36 survey questions (n = 1000). The KMO value was 0.94, showing the data was suitable for factor analysis, and all individual measures MSA were above 0.90. Bartlett’s test of sphericity was significant (p < 0.001), confirming the correlations between items.

Based on parallel analysis, 5 factors were chosen, and oblique rotation was used. Seven questions were removed due to low communalities and high Hoffmans index. The final 5 factors were:

•   Factor 1 (λ̂1 = 4.36): Avoidance of Closeness
•   Factor 2 (λ̂2 = 3.48): Anxiety in Relationships
•   Factor 3 (λ̂3 = 3.42): Emotional Support
•   Factor 4 (λ̂4 = 2.35): Frustration
•   Factor 5 (λ̂5 = 1.98): Fear of Overdependence

These 5 factors explain 56% of the variation in the data and provide insights into key aspects of close relationships.

Factor reliability (Cronbach’s alpha) was calculated for each F5, with acceptable reliability (α > 0.8).