# NOT RUN {
library(car)
xml.path <- system.file("", "example_lm.xml", package = "xplain")
# Example of a wrapper function for lm()
lm.xplain <- function(formula, data, subset, weights, na.action,
method = "qr", model = TRUE, x = FALSE, y = FALSE, qr = TRUE,
singular.ok = TRUE, contrasts = NULL, offset, ...) {
call<-xplain.getcall("lm")
xplain(call, xml=xml.path)
}
lm.xplain(education ~ young + income + urban, data=Anscombe)
# }
Run the code above in your browser using DataLab