I am trying to create a linear model using R. I have imported a dataset from Excel that had some blank cells. I copied and pasted certain cols that all contained the same number of rows. I cannot create the model as I am getting an error message. I am not even using the lm.fit function.
I have tried using only one independent variable but still does not work.
mod1 <- lm(Price_Change~SurpEPS+SurpNI+SurpRev)
Error in lm.fit(x, y, offset = offset, singular.ok = singular.ok, ...) : NA/NaN/Inf in 'y' In addition: Warning message: In storage.mode(v) <- "double" : NAs introduced by coercion