library(tidyverse)
library(here)
SandraModel <-
"autoritario =~ i1 , i2 + i3 +i4
democratico =~ i5 + i6 + i7 +i8
permisivo =~ i9 + i10 + i11 +i12
sobreprotector =~ i13 + i14 + i15 +i16
integral =~ i17 + i18 + i19 +i20
inatencion =~ i21 + i22 + i23 + i24 + i25
hiperac_imp =~ i26 + i27 + i28 + i29
EEF =~ autoritario + democratico + permisivo + sobreprotector + integral
TDAH =~ inatencion + hiperac_imp
TDAH =~ EEF"
sandra_raw <- read_csv(here("SEM lavaan/data_sem", "sandra.csv"))
Por medio del Cronbach Alpha.
alpha(sandra_raw %>%
select(i1, i2, i3, i4))
Reliability analysis
Call: alpha(x = sandra_raw %>% select(i1, i2, i3, i4))
lower alpha upper 95% confidence boundaries
0.85 0.87 0.88
Reliability if an item is dropped:
Item statistics
Non missing response frequency for each item
1 2 3 4 5 6 7 miss
i1 0.02 0.07 0.17 0.34 0.27 0.10 0.03 0
i2 0.00 0.03 0.19 0.37 0.29 0.10 0.01 0
i3 0.00 0.04 0.19 0.35 0.31 0.10 0.01 0
i4 0.02 0.12 0.32 0.33 0.16 0.03 0.01 0
Por medio del Cronbach Alpha.
alpha(sandra_raw %>%
select(i5, i6, i7, i8))
Reliability analysis
Call: alpha(x = sandra_raw %>% select(i5, i6, i7, i8))
lower alpha upper 95% confidence boundaries
0.82 0.84 0.85
Reliability if an item is dropped:
Item statistics
Non missing response frequency for each item
1 2 3 4 5 6 7 miss
i5 0.01 0.07 0.22 0.38 0.24 0.06 0.01 0
i6 0.01 0.06 0.20 0.34 0.28 0.09 0.02 0
i7 0.02 0.12 0.28 0.38 0.17 0.03 0.01 0
i8 0.01 0.11 0.28 0.34 0.20 0.06 0.01 0
Por medio del Cronbach Alpha.
alpha(sandra_raw %>%
select(i9, i10, i11, i12))
Reliability analysis
Call: alpha(x = sandra_raw %>% select(i9, i10, i11, i12))
lower alpha upper 95% confidence boundaries
0.83 0.85 0.86
Reliability if an item is dropped:
Item statistics
Non missing response frequency for each item
1 2 3 4 5 6 7 miss
i9 0.01 0.07 0.24 0.38 0.22 0.07 0.01 0
i10 0.01 0.08 0.20 0.32 0.27 0.10 0.03 0
i11 0.00 0.06 0.23 0.41 0.22 0.06 0.01 0
i12 0.00 0.01 0.09 0.30 0.38 0.18 0.04 0
Por medio del Cronbach Alpha.
alpha(sandra_raw %>%
select(i13, i14, i15, i16))
Reliability analysis
Call: alpha(x = sandra_raw %>% select(i13, i14, i15, i16))
lower alpha upper 95% confidence boundaries
0.84 0.85 0.87
Reliability if an item is dropped:
Item statistics
Non missing response frequency for each item
1 2 3 4 5 6 7 miss
i13 0.01 0.07 0.30 0.40 0.18 0.03 0.00 0
i14 0.02 0.09 0.28 0.34 0.21 0.05 0.01 0
i15 0.02 0.12 0.29 0.33 0.19 0.05 0.00 0
i16 0.02 0.09 0.28 0.34 0.22 0.05 0.00 0
Por medio del Cronbach Alpha.
alpha(sandra_raw %>%
select(i17, i18, i19, i20))
Reliability analysis
Call: alpha(x = sandra_raw %>% select(i17, i18, i19, i20))
lower alpha upper 95% confidence boundaries
0.85 0.86 0.88
Reliability if an item is dropped:
Item statistics
Non missing response frequency for each item
1 2 3 4 5 6 7 miss
i17 0.01 0.06 0.21 0.38 0.25 0.07 0.01 0
i18 0.00 0.08 0.25 0.36 0.24 0.05 0.01 0
i19 0.02 0.10 0.23 0.32 0.21 0.09 0.03 0
i20 0.00 0.06 0.24 0.39 0.24 0.06 0.01 0
Por medio del Cronbach Alpha.
alpha(sandra_raw %>%
select(i23, i24, i25, i26))
Reliability analysis
Call: alpha(x = sandra_raw %>% select(i23, i24, i25, i26))
lower alpha upper 95% confidence boundaries
0.73 0.75 0.78
Reliability if an item is dropped:
Item statistics
Non missing response frequency for each item
1 2 3 4 5 6 7 miss
i23 0.01 0.05 0.24 0.37 0.26 0.07 0.00 0
i24 0.01 0.09 0.25 0.36 0.23 0.06 0.01 0
i25 0.01 0.06 0.25 0.33 0.25 0.09 0.01 0
i26 0.01 0.10 0.25 0.34 0.23 0.06 0.01 0
Por medio del Cronbach Alpha.
alpha(sandra_raw %>%
select(i27, i28, i29))
Reliability analysis
Call: alpha(x = sandra_raw %>% select(i27, i28, i29))
lower alpha upper 95% confidence boundaries
0.79 0.81 0.83
Reliability if an item is dropped:
Item statistics
Non missing response frequency for each item
1 2 3 4 5 6 7 miss
i27 0.01 0.06 0.22 0.37 0.24 0.09 0.01 0
i28 0.02 0.09 0.32 0.36 0.18 0.03 0.00 0
i29 0.01 0.05 0.21 0.34 0.27 0.10 0.02 0
Construimos el modelo
sandra_model_LM <-
lm(TDAH ~ EEF + genero,
data = sandra_LM)
Revisamos el modelo
summary(sandra_model_LM)
Call:
lm(formula = TDAH ~ EEF + genero, data = sandra_LM)
Residuals:
Min 1Q Median 3Q Max
-2.35667 -0.48016 -0.00596 0.47643 2.21192
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 1.95534 0.12390 15.782 <2e-16 ***
EEF 0.50712 0.03046 16.647 <2e-16 ***
generom 0.02170 0.04670 0.465 0.642
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Residual standard error: 0.6815 on 997 degrees of freedom
Multiple R-squared: 0.2186, Adjusted R-squared: 0.217
F-statistic: 139.4 on 2 and 997 DF, p-value: < 2.2e-16