-
Notifications
You must be signed in to change notification settings - Fork 0
/
analysis.txt
149 lines (126 loc) · 6.96 KB
/
analysis.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
[1] "age" "job" "marital" "education" "default" "balance" "housing" "loan"
[9] "contact" "day" "month" "duration" "campaign" "pdays" "previous" "poutcome"
[17] "y"
===========================================================================================================
factor columns
default
housing
loan
y
dummy columns
poutcome
contact
marital
job
===========================================================================================================
Call:
glm(formula = bank_filtered$y ~ ., family = "binomial", data = bank_filtered)
Deviance Residuals:
Min 1Q Median 3Q Max
-5.7075 -0.4059 -0.2709 -0.1614 3.4793
Coefficients:
Estimate Std. Error z value Pr(>|z|)
(Intercept) -2.237e+00 3.105e-01 -7.204 5.87e-13 ***
age 1.722e-03 2.149e-03 0.801 0.422855
job.job.admin. 3.405e-01 2.294e-01 1.484 0.137808
job.job.blue.collar -5.471e-02 2.288e-01 -0.239 0.810971
job.job.entrepreneur -1.402e-01 2.491e-01 -0.563 0.573411
job.job.housemaid -1.777e-01 2.528e-01 -0.703 0.481998
job.job.management 1.189e-01 2.278e-01 0.522 0.601794
job.job.retired 6.792e-01 2.333e-01 2.912 0.003595 **
job.job.self.employed -3.240e-02 2.426e-01 -0.134 0.893755
job.job.services 2.718e-02 2.332e-01 0.117 0.907239
job.job.student 8.453e-01 2.405e-01 3.515 0.000440 ***
job.job.technician 7.461e-02 2.278e-01 0.328 0.743219
job.job.unemployed 1.057e-01 2.427e-01 0.435 0.663302
marital.marital.divorced -1.553e-01 6.545e-02 -2.373 0.017628 *
marital.marital.married -3.130e-01 4.470e-02 -7.001 2.54e-12 ***
education.education.primary -2.706e-01 1.012e-01 -2.674 0.007498 **
education.education.secondary -1.041e-01 8.875e-02 -1.173 0.240615
education.education.tertiary 1.334e-01 9.327e-02 1.431 0.152471
default -1.558e-01 1.616e-01 -0.964 0.334893
balance 1.854e-05 4.864e-06 3.812 0.000138 ***
housing -7.788e-01 3.972e-02 -19.608 < 2e-16 ***
loan -5.603e-01 5.821e-02 -9.625 < 2e-16 ***
contact.contact.cellular 1.174e+00 5.806e-02 20.227 < 2e-16 ***
contact.contact.telephone 1.090e+00 8.854e-02 12.308 < 2e-16 ***
day -4.168e-03 2.132e-03 -1.954 0.050643 .
month -1.846e-02 6.688e-03 -2.761 0.005766 **
duration 4.055e-03 6.277e-05 64.591 < 2e-16 ***
campaign -1.061e-01 9.962e-03 -10.652 < 2e-16 ***
pdays 1.213e-04 3.021e-04 0.401 0.688145
previous 1.025e-02 6.563e-03 1.561 0.118473
poutcome.poutcome.failure 2.454e-01 9.072e-02 2.705 0.006832 **
poutcome.poutcome.other 4.912e-01 1.030e-01 4.771 1.84e-06 ***
poutcome.poutcome.success 2.551e+00 8.358e-02 30.525 < 2e-16 ***
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
(Dispersion parameter for binomial family taken to be 1)
Null deviance: 32631 on 45210 degrees of freedom
Residual deviance: 22592 on 45178 degrees of freedom
AIC: 22658
Number of Fisher Scoring iterations: 6
> accuray
[1] 0.9002455
===========================================================================================================
Call:
glm(formula = bank_filtered_upgrd$y ~ bank_filtered_upgrd$Comp.1 +
bank_filtered_upgrd$Comp.2 + bank_filtered_upgrd$Comp.3 +
bank_filtered_upgrd$Comp.4 + bank_filtered_upgrd$Comp.5 +
bank_filtered_upgrd$Comp.6 + bank_filtered_upgrd$Comp.7 +
bank_filtered_upgrd$Comp.8 + bank_filtered_upgrd$Comp.9 +
bank_filtered_upgrd$Comp.10 + bank_filtered_upgrd$Comp.11 +
bank_filtered_upgrd$Comp.12 + bank_filtered_upgrd$Comp.13 +
bank_filtered_upgrd$Comp.14 + bank_filtered_upgrd$Comp.15 +
bank_filtered_upgrd$Comp.16 + bank_filtered_upgrd$Comp.17 +
bank_filtered_upgrd$Comp.18 + bank_filtered_upgrd$Comp.19 +
bank_filtered_upgrd$Comp.20 + bank_filtered_upgrd$Comp.21 +
bank_filtered_upgrd$Comp.22 + bank_filtered_upgrd$Comp.23 +
bank_filtered_upgrd$Comp.24 + bank_filtered_upgrd$Comp.25 +
bank_filtered_upgrd$Comp.26 + bank_filtered_upgrd$Comp.27 +
bank_filtered_upgrd$Comp.28, family = "binomial", data = bank_filtered_upgrd)
Deviance Residuals:
Min 1Q Median 3Q Max
-4.613e-06 -2.538e-06 -2.285e-06 -2.057e-06 5.795e-06
Coefficients:
Estimate Std. Error z value Pr(>|z|)
(Intercept) -2.039e+01 1.670e+03 -0.012 0.990
bank_filtered_upgrd$Comp.1 -3.160e+00 1.054e+03 -0.003 0.998
bank_filtered_upgrd$Comp.2 -1.512e+00 1.101e+03 -0.001 0.999
bank_filtered_upgrd$Comp.3 1.513e+00 1.193e+03 0.001 0.999
bank_filtered_upgrd$Comp.4 6.091e+00 1.279e+03 0.005 0.996
bank_filtered_upgrd$Comp.5 -6.666e+00 1.363e+03 -0.005 0.996
bank_filtered_upgrd$Comp.6 -3.390e+00 1.411e+03 -0.002 0.998
bank_filtered_upgrd$Comp.7 -7.810e-01 1.487e+03 -0.001 1.000
bank_filtered_upgrd$Comp.8 9.946e-01 1.486e+03 0.001 0.999
bank_filtered_upgrd$Comp.9 2.587e+00 1.540e+03 0.002 0.999
bank_filtered_upgrd$Comp.10 -2.739e+00 1.563e+03 -0.002 0.999
bank_filtered_upgrd$Comp.11 5.385e-01 1.537e+03 0.000 1.000
bank_filtered_upgrd$Comp.12 7.406e-04 1.609e+03 0.000 1.000
bank_filtered_upgrd$Comp.13 -1.980e+00 1.595e+03 -0.001 0.999
bank_filtered_upgrd$Comp.14 -3.266e-01 1.696e+03 0.000 1.000
bank_filtered_upgrd$Comp.15 -1.061e+00 1.617e+03 -0.001 0.999
bank_filtered_upgrd$Comp.16 -8.132e-01 1.608e+03 -0.001 1.000
bank_filtered_upgrd$Comp.17 3.336e-02 1.698e+03 0.000 1.000
bank_filtered_upgrd$Comp.18 3.151e-02 1.708e+03 0.000 1.000
bank_filtered_upgrd$Comp.19 1.315e+00 1.713e+03 0.001 0.999
bank_filtered_upgrd$Comp.20 3.430e-01 1.744e+03 0.000 1.000
bank_filtered_upgrd$Comp.21 -1.162e-01 1.836e+03 0.000 1.000
bank_filtered_upgrd$Comp.22 1.247e+00 1.823e+03 0.001 0.999
bank_filtered_upgrd$Comp.23 -2.469e-01 1.859e+03 0.000 1.000
bank_filtered_upgrd$Comp.24 -1.078e+00 1.948e+03 -0.001 1.000
bank_filtered_upgrd$Comp.25 -3.289e+00 2.491e+03 -0.001 0.999
bank_filtered_upgrd$Comp.26 8.983e-01 2.175e+03 0.000 1.000
bank_filtered_upgrd$Comp.27 1.181e+01 2.368e+03 0.005 0.996
bank_filtered_upgrd$Comp.28 -2.733e+00 2.476e+03 -0.001 0.999
(Dispersion parameter for binomial family taken to be 1)
Null deviance: 3.2631e+04 on 45210 degrees of freedom
Residual deviance: 2.6392e-07 on 45182 degrees of freedom
AIC: 58
Number of Fisher Scoring iterations: 25
confusion1
0 1
FALSE 39922 0
TRUE 0 5289
> accuray
[1] 1