# \donttest{
# linear model
x <- 1:10
y <- 0.5*x + 10
boot <- bootstrap_regression(data.frame(x,y),"y~x")
# polynomial model, call to I() needed for squaring x in equation string
x <- 1:10
y <- x + x^2
boot <- bootstrap_regression(data.frame(x,y),"y ~ x+I(x^2)")
# power law model
# BCF returned since y is transformed to log units
x <- 1:10
y <- x^0.3
boot <- bootstrap_regression(data.frame(x,y),"log10(y)~log10(x)")
# multivariate model
a <- 1:10
b <- a*2
c <- a^2*b^3
boot <- bootstrap_regression(data.frame(a,b,c),"log10(c)~log10(a)+log10(b)")
# }
Run the code above in your browser using DataLab