newdata had 1 row but variables found have code example Example: newdata had 1 row but variables found have predict(fit,data.frame(x=mean(x)), interval="confidence")