问题 I'm having a trouble when creating a function that calls the lm() function: regresionLineal <- function (vardep, varindep1, varindep2, DATA) { lm(vardep ~ varindep1 + varindep2, data = DATA) } Then I call it using data from a data frame I created previously ( DATOS )... regresionLineal(Estatura, Largo, Ancho, DATOS) Error in eval(expr, envir, enclos) : object 'Estatura' not found Called from: eval(expr, envir, enclos) Any help will be welcome... 回答1: You should do: regresionLineal <- function