when using the light_profile function the by option only works when one variable is entred, when more than one variable is used the error listed bellow is displayed. Previously one could enter multiple rows and get a data frame that has predictions based on the desired variables.
fit <- lm(Sepal.Length ~ ., data = iris)
fl <- flashlight(model = fit, label = "iris", data = iris, y = "Sepal.Length")
light_profile(fl, v = "Petal.Length",
by = c("Species","Sepal.Width"),
type = 'predicted')
Error in nm %in% nms && !is.null(x[[nm]]) && !(x[[nm]] %in% colnames(x$data)) :
'length = 2' in coercion to 'logical(1)'
when using the light_profile function the by option only works when one variable is entred, when more than one variable is used the error listed bellow is displayed. Previously one could enter multiple rows and get a data frame that has predictions based on the desired variables. fit <- lm(Sepal.Length ~ ., data = iris) fl <- flashlight(model = fit, label = "iris", data = iris, y = "Sepal.Length")
light_profile(fl, v = "Petal.Length", by = c("Species","Sepal.Width"), type = 'predicted')
Error in nm %in% nms && !is.null(x[[nm]]) && !(x[[nm]] %in% colnames(x$data)) : 'length = 2' in coercion to 'logical(1)'