powered by
A sample of 82 cars with variables speed and miles per gallon collected.
data("speed")
A data frame with 82 observations on the following 2 variables.
mpg
Miles per gallon
sp
a numeric vector
Kloke, J. and McKean, J.W. (2014), Nonparametric statistcal methods using R, Boca Raton, FL: Chapman-Hall.
data(speed) plot(sp~mpg,data=speed) rfit(sp~mpg+I(mpg^2),data=speed)
Run the code above in your browser using DataLab