-
Notifications
You must be signed in to change notification settings - Fork 0
/
Results_2.txt
executable file
·240 lines (193 loc) · 6.58 KB
/
Results_2.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
> shapiro.test(data_wo_demoday$score_object)
Shapiro-Wilk normality test
data: data_wo_demoday$score_object
W = 0.9023, p-value = 0.03879
> aggregate(score_object ~ group, data_rel, mean)
group score_object
1 app 0.4727273
2 text 0.2600000
> aggregate(score_object ~ group, data_rel, median)
group score_object
1 app 0.4
2 text 0.2
> aggregate(score_general ~ group, data_rel, mean)
group score_general
1 app 0.5000000
2 text 0.5333333
> aggregate(score_general ~ group, data_rel, median)
group score_general
1 app 0.5
2 text 0.5
> sd(text_data$score_object)
[1] 0.2727319
> sd(text_data$score_general)
[1] 0.4067334
> sd(app_data$score_object)
[1] 0.2388948
> sd(app_data$score_general)
[1] 0.4533824
> var(text_data$score_object)
[1] 0.07438272
> var(app_data$score_object)
[1] 0.05707071
> var(text_data$score_general)
[1] 0.1654321
> var(app_data$score_general)
[1] 0.2055556
> age_ordered <- factor(data_wo_demoday$age, ordered = TRUE, levels = levels(data_wo_demoday$age))
> summary(age_ordered)
18 - 24 25 - 30 31 - 40 41 - 50 51 - 60 60+
12 5 0 0 1 3
> quantile(age_ordered, 0.25, type=1)
25%
18 - 24
Levels: 18 - 24 < 25 - 30 < 31 - 40 < 41 - 50 < 51 - 60 < 60+
> quantile(age_ordered, 0.5, type=1)
50%
18 - 24
Levels: 18 - 24 < 25 - 30 < 31 - 40 < 41 - 50 < 51 - 60 < 60+
> quantile(age_ordered, 0.75, type=1)
75%
25 - 30
Levels: 18 - 24 < 25 - 30 < 31 - 40 < 41 - 50 < 51 - 60 < 60+
>
> age_ordered <- factor(text_data$age, ordered = TRUE, levels = levels(text_data$age))
> summary(age_ordered)
18 - 24 25 - 30 31 - 40 41 - 50 51 - 60 60+
5 3 0 0 0 2
> quantile(age_ordered, 0.25, type=1)
25%
18 - 24
Levels: 18 - 24 < 25 - 30 < 31 - 40 < 41 - 50 < 51 - 60 < 60+
> quantile(age_ordered, 0.5, type=1)
50%
18 - 24
Levels: 18 - 24 < 25 - 30 < 31 - 40 < 41 - 50 < 51 - 60 < 60+
> quantile(age_ordered, 0.75, type=1)
75%
25 - 30
Levels: 18 - 24 < 25 - 30 < 31 - 40 < 41 - 50 < 51 - 60 < 60+
>
> age_ordered <- factor(app_data$age, ordered = TRUE, levels = levels(app_data$age))
> summary(age_ordered)
18 - 24 25 - 30 31 - 40 41 - 50 51 - 60 60+
7 2 0 0 1 1
> quantile(age_ordered, 0.25, type=1)
25%
18 - 24
Levels: 18 - 24 < 25 - 30 < 31 - 40 < 41 - 50 < 51 - 60 < 60+
> quantile(age_ordered, 0.5, type=1)
50%
18 - 24
Levels: 18 - 24 < 25 - 30 < 31 - 40 < 41 - 50 < 51 - 60 < 60+
> quantile(age_ordered, 0.75, type=1)
75%
25 - 30
Levels: 18 - 24 < 25 - 30 < 31 - 40 < 41 - 50 < 51 - 60 < 60+
Kruskal-Wallis rank sum test
data: data_rel$score_object by data_rel$group
Kruskal-Wallis chi-squared = 3.0992, df = 1, p-value = 0.07833
Quantile Regression
Call: rq(formula = score_object ~ group + score_general, tau = i, data = data_rel)
tau: [1] 0.25
Coefficients:
coefficients lower bd upper bd
(Intercept) 0.16667 -0.05241 0.49896
grouptext -0.16667 -0.33333 0.01809
score_general 0.00000 -0.42955 0.25000
Quantile Regression Analysis of Deviance Table
Model 1: score_object ~ group + score_general
Model 2: score_object ~ 1
Df Resid Df F value Pr(>F)
1 2 18 1.1719 0.3323
Call: rq(formula = score_object ~ group + score_general, tau = i, data = data_rel)
tau: [1] 0.5
Coefficients:
coefficients lower bd upper bd
(Intercept) 0.50000 0.20980 0.83333
grouptext -0.19444 -0.49507 0.00000
score_general -0.16667 -0.45490 0.17463
Quantile Regression Analysis of Deviance Table
Model 1: score_object ~ group + score_general
Model 2: score_object ~ 1
Df Resid Df F value Pr(>F)
1 2 18 1.4035 0.2714
Call: rq(formula = score_object ~ group + score_general, tau = i, data = data_rel)
tau: [1] 0.75
Coefficients:
coefficients lower bd upper bd
(Intercept) 0.72222 0.50000 1.06787
grouptext -0.22222 -0.34752 0.04571
score_general -0.33333 -0.50000 -0.16667
Quantile Regression Analysis of Deviance Table
Model 1: score_object ~ group + score_general
Model 2: score_object ~ 1
Df Resid Df F value Pr(>F)
1 2 18 3.7754 0.04274 *
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Warning messages:
1: In rq.fit.br(x, y, tau = tau, ...) : Solution may be nonunique
2: In rq.fit.br(x, y, tau = tau, ci = TRUE, ...) :
Solution may be nonunique
> summary(gam_model)
Family: gaussian
Link function: identity
Formula:
score_object ~ group + s(score_general, k = 6, bs = "ps")
Parametric coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 0.36671 0.06106 6.006 1.76e-05 ***
grouptext -0.12009 0.08951 -1.342 0.198
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Approximate significance of smooth terms:
edf Ref.df F p-value
s(score_general) 2.838 3.179 4.338 0.0202 *
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
R-sq.(adj) = 0.428 Deviance explained = 53.8%
GCV = 0.052159 Scale est. = 0.040143 n = 21
> test
Likelihood ratio test
Model 1: score_object ~ group + s(score_general, k = 6, bs = "ps")
Model 2: score_object ~ 1
#Df LogLik Df Chisq Pr(>Chisq)
1 5.8378 6.7125
2 2.0000 -1.3988 -3.8378 16.223 0.002735 **
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
ORDINARY NONPARAMETRIC BOOTSTRAP
Call:
boot(data = data_rel, statistic = bs_stat, R = 1500, formula = score_object ~
group)
Bootstrap Statistics :
original bias std. error
t1* 0.4727273 -0.002150219 0.08433468
t2* 0.2600000 -0.003765203 0.10071253
t3* 0.4000000 0.064533333 0.11456089
t4* 0.2000000 -0.034533333 0.12068067
> colMeans(boot_stat$t)
[1] 0.4705771 0.2562348 0.4645333 0.1654667
ORDINARY NONPARAMETRIC BOOTSTRAP
Call:
boot(data = data_rel, statistic = bs_stat, R = 1500, formula = score_general ~
group)
Bootstrap Statistics :
original bias std. error
t1* 0.5000000 0.002461908 0.1374322
t2* 0.5333333 -0.001618129 0.1267375
t3* 0.5000000 0.006055556 0.3129547
t4* 0.5000000 0.037166667 0.2349801
> colMeans(boot_stat$t)
[1] 0.5024619 0.5317152 0.5060556 0.5371667
ORDINARY NONPARAMETRIC BOOTSTRAP
Call:
boot(data = data_rel, statistic = bs_test, R = 1500)
Bootstrap Statistics :
original bias std. error
t1* 3.099207 0.7656093 3.154247
t2* 1.000000 0.0000000 0.000000
> test_res <- colMeans(boot_test$t)
> pchisq(test_res[1], df=test_res[2], lower.tail=FALSE)
[1] 0.04930859