Last chance! 50% off unlimited learning
Sale ends in
# NOT RUN {
# Load German credit data
data(germancredit)
# Example I
dt1 <- germancredit[, c("creditability", "credit.amount")]
bins1 <- woebin(dt1, y="creditability")
p1 <- woebin_plot(bins1)
# }
# NOT RUN {
# Example II
bins <- woebin(germancredit, y="creditability")
plotlist <- woebin_plot(bins)
# # save binning plot
# for (i in 1:length(plotlist)) {
# ggplot2::ggsave(
# paste0("./woebinplot/", names(plotlist[i]), ".png"), plotlist[[i]],
# width = 15, height = 9, units="cm" )
# }
# }
# NOT RUN {
# }
Run the code above in your browser using DataLab