Leia…
avatuse mediaanväärtus (kirjuta kood allolevale reale)
median(tabel$avatus)
## [1] 124.5
sotsiaalsuse standardhälve
sd(tabel$sotsiaalsus, na.rm = TRUE)
## [1] 17.63919
neurootilisuse keskmine
mean(tabel$neurootilisus)
## [1] 87.89
Millises vahemikus varieeruvad ekstravertsuse skoorid?
range(tabel$ekstravertsus)
## [1] 8 168
Kas maa- ja linnaelanike keskmised erinevad…
avatuse osas?
t.test(tabel$avatus~tabel$elukoht)
##
## Welch Two Sample t-test
##
## data: tabel$avatus by tabel$elukoht
## t = -1.5747, df = 182.67, p-value = 0.1171
## alternative hypothesis: true difference in means is not equal to 0
## 95 percent confidence interval:
## -10.510193 1.180114
## sample estimates:
## mean in group maa mean in group linn
## 120.4943 125.1593
ekstravertsuse osas?
t.test(tabel$ekstravertsus~tabel$elukoht)
##
## Welch Two Sample t-test
##
## data: tabel$ekstravertsus by tabel$elukoht
## t = -1.9487, df = 192.29, p-value = 0.05279
## alternative hypothesis: true difference in means is not equal to 0
## 95 percent confidence interval:
## -14.47289314 0.08737794
## sample estimates:
## mean in group maa mean in group linn
## 98.81609 106.00885
sotsiaalsuse osas?
t.test(tabel$sotsiaalsus~tabel$elukoht)
##
## Welch Two Sample t-test
##
## data: tabel$sotsiaalsus by tabel$elukoht
## t = -2.6916, df = 168.05, p-value = 0.007829
## alternative hypothesis: true difference in means is not equal to 0
## 95 percent confidence interval:
## -11.815346 -1.816838
## sample estimates:
## mean in group maa mean in group linn
## 122.1839 129.0000
meelekindluse osas
t.test(tabel$meelekindlus~tabel$elukoht)
##
## Welch Two Sample t-test
##
## data: tabel$meelekindlus by tabel$elukoht
## t = 0.1464, df = 192.21, p-value = 0.8838
## alternative hypothesis: true difference in means is not equal to 0
## 95 percent confidence interval:
## -5.715049 6.631483
## sample estimates:
## mean in group maa mean in group linn
## 113.8276 113.3694
neurootilisuse osas?
t.test(tabel$neurootilisus~tabel$elukoht)
##
## Welch Two Sample t-test
##
## data: tabel$neurootilisus by tabel$elukoht
## t = -0.42309, df = 186.43, p-value = 0.6727
## alternative hypothesis: true difference in means is not equal to 0
## 95 percent confidence interval:
## -8.113641 5.248012
## sample estimates:
## mean in group maa mean in group linn
## 87.08046 88.51327
Kui tugev on seisundi- ja püsiärevuse vaheline korrelatsioon?
Kas need korrelatsioonikordajad on statistiliselt olulised?
cor.test(tabel$stateanx, tabel$traitanx)
##
## Pearson's product-moment correlation
##
## data: tabel$stateanx and tabel$traitanx
## t = 9.6538, df = 197, p-value < 2.2e-16
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
## 0.4642002 0.6542233
## sample estimates:
## cor
## 0.5667008
…neurootlisuse ja ekstravertsuse vaheline korrelatsioon?
cor.test(tabel$neurootilisus, tabel$ekstravertsus)
##
## Pearson's product-moment correlation
##
## data: tabel$neurootilisus and tabel$ekstravertsus
## t = 0.094603, df = 198, p-value = 0.9247
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
## -0.1321413 0.1453284
## sample estimates:
## cor
## 0.00672297
…depressiooni ja p?si?revuse vaheline korrelatsioon?
cor(tabel$depressioon, tabel$traitanx)
## [1] 0.6592369
cor.test(tabel$depressioon, tabel$traitanx)
##
## Pearson's product-moment correlation
##
## data: tabel$depressioon and tabel$traitanx
## t = 12.337, df = 198, p-value < 2.2e-16
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
## 0.5728947 0.7311084
## sample estimates:
## cor
## 0.6592369