1 簡單線性迴歸
fit
= lm(weight~height, data=women) summary(fit) women$weight fitted(fit) residuals(fit) par(mar=rep( 0 , 4 )) plot(women$height,
women$weight, xlab= "Height" ,
ylab= "Weight" ) |
fit
= lm(weight~height, data=women) summary(fit) women$weight fitted(fit) residuals(fit) par(mar=rep( 0 , 4 )) plot(women$height,
women$weight, xlab= "Height" ,
ylab= "Weight" ) |