library(earth) data(etitanic) # we use an earth model here, but plotd works with any model fit <- earth(survived ~ ., data=etitanic, degree=2, glm=list(family=binomial)) plotd(fit, main="plotd example 1", type="response")