Hello, I'm trying to plot a fitted lm() line on a plot when the one explanatory variable is log transformed and log="x". I get different lines using abline and predict.lm().
#Example x <- 1:100 y <- rnorm(100) plot(y ~ x, log="x") abline(lm(y ~ log(x))) lines(x, predict(lm(y ~ log(x))), lwd=2) I'm sure I'm missing something but could someone tell me which line is correct? Thanks. Richard -- Richard Chandler, M.S. candidate Department of Natural Resources Conservation UMass Amherst (413)545-1237 ______________________________________________ [email protected] mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
