Very similar to this; How are the standard errors computed for the fitted values from a logistic regression? Although after manual calculation of se.fit with glm family = binomial rather than default?
Model fit and example;
> summary(logistic.model)
Call:
glm(formula = LossIncurred ~ ExposureYear + Quo_AmountFinanced +
LVR + Loan_VedaScore + ResidualPercentage + AssetAge + PropertyOwned +
RatingScore, family = "binomial", data = Default_data.train)
Deviance Residuals:
Min 1Q Median 3Q Max
-0.6256 -0.0822 -0.0525 -0.0346 3.8582
Coefficients:
Estimate Std. Error z value Pr(>|z|)
(Intercept) -7.400e+00 5.609e-01 -13.192 < 2e-16 ***
ExposureYear 7.039e-01 5.730e-02 12.283 < 2e-16 ***
Quo_AmountFinanced 3.763e-06 1.771e-06 2.124 0.033660 *
LVR 1.554e+00 4.804e-01 3.234 0.001221 **
Loan_VedaScoreAverage -6.589e-01 1.921e-01 -3.430 0.000604 ***
Loan_VedaScoreGood -1.575e+00 2.016e-01 -7.811 5.69e-15 ***
Loan_VedaScoreVery Good -2.522e+00 2.637e-01 -9.566 < 2e-16 ***
Loan_VedaScoreExcellent -3.255e+00 5.246e-01 -6.205 5.46e-10 ***
ResidualPercentage 8.173e-01 5.034e-01 1.624 0.104469
AssetAge 9.256e-02 2.464e-02 3.757 0.000172 ***
PropertyOwned -5.768e-01 1.650e-01 -3.495 0.000475 ***
RatingScore -1.314e-01 3.778e-02 -3.477 0.000506 ***
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
(Dispersion parameter for binomial family taken to be 1)
Null deviance: 2661.4 on 57163 degrees of freedom
Residual deviance: 2304.7 on 57152 degrees of freedom
(355 observations deleted due to missingness)
AIC: 2328.7
Number of Fisher Scoring iterations: 10
Essentially needing to manually calculate the below value
predictTest <- predict(logistic.model, newdata = Default_data.test, type = "response", se.fit = TRUE)
> predictTest$se.fit[1]
1
0.0006774337