x<- c(0,10,20,30,40,50,60,70,80)
y<- c(0,0.33,0.605,0.897,1.115,1.394,1.687,1.954,2.198)
plot(x,y)
fit<- lm(y~x)
abline(fit,lwd=0.5)
title(main="标准曲线",xlab="染料浓度(mg/l)",ylab="吸光值")
x<- c(0,10,20,30,40,50,60,70,80) y<- c(0,0.33,0.605,0.897,1.115,1.394,1.687,1.954,2.198) plot(x,y,main="标准曲线",xlab="染料浓度(mg/l)",ylab="吸光值") fit<- lm(y~x) abline(fit,lwd=0.5)
把 title(main="标准曲线",xlab="染料浓度(mg/l)",ylab="吸光值") 这行代码直接放到plot里面就好了。