Skip to content

cannot get outcome names for workflows using add_variables() #993

@topepo

Description

@topepo
library(tidymodels)

lm_mod <- parsnip::linear_reg() %>% parsnip::set_engine("lm")
wflow <- workflow() %>% add_model(lm_mod)

wflow_1 <- wflow %>% add_variables(outcomes = "mpg", predictors = c(wt))

outcome_names(wflow_1)
#> Error in UseMethod("outcome_names"): no applicable method for 'outcome_names' applied to an object of class "workflow_variables"

Created on 2025-03-20 with reprex v2.1.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    featurea feature request or enhancement

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions