I am asked to find a threshold that can achieve 80% sensitivity. However, I am unable to find a reasonable one from my logistic regression model. Can anyone show me where the problem is please?
Code:
coords(roc1,x= 0.8,input="sensitivity")
threshold specificity sensitivity
NA 0.5648283 0.8000000
Code:
pred4<-predict(Model$BestModel,newdata=Data,type="response")
class.pred4<-1*(pred4>0.1)
T4<-table(Data$y,class.pred4)
T4
Sen4<-T4[2,2]/sum(T4[2,])
Sen4
class.pred4
0 1
0 4290 1331
1 249 512
0.6727989
Last edited: