Professional Documents
Culture Documents
Leng R
Leng R
> y = c(560986, 549194, 610223, 726742, 651834, 568010, 592160, 637450, 696181, 727857,
760590, 581705)
> plot(x,y, pch=20, col="black", xlab="PRES ($/Kg)", ylab="CRES (ton/año)", main="Diagrama de
dispersión")
> #Regresión Exponencial#
> yp = log(y)
> reg1 = lm(yp~x)
> summary (reg1)
Call:
lm(formula = yp ~ x)
Residuals:
Min 1Q Median 3Q Max
-0.16361 -0.08563 0.02575 0.06164 0.16855
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 1.330e+01 5.041e-02 263.915 <2e-16 ***
x 2.569e-05 1.792e-05 1.433 0.182
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Call:
lm(formula = yp ~ xp)
Residuals:
Min 1Q Median 3Q Max
-0.14509 -0.09748 0.01611 0.07966 0.15786
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 13.02352 0.24389 53.400 1.28e-13 ***
xp 0.04622 0.03312 1.396 0.193
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Residual standard error: 0.1089 on 10 degrees of freedom
Multiple R-squared: 0.163, Adjusted R-squared: 0.07931
F-statistic: 1.948 on 1 and 10 DF, p-value: 0.1931
Call:
lm(formula = y ~ x + I(x^2))
Residuals:
Min 1Q Median 3Q Max
-97354 -59923 12042 41537 109415
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 5.894e+05 5.425e+04 10.864 1.79e-06 ***
x 3.351e+01 6.065e+01 0.553 0.594
I(x^2) -3.129e-03 1.124e-02 -0.278 0.787
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
> a3 = 5.894e+05
> b3 = 3.351e+01
> c3 = -3.129e-03
> curve (a3+(b3*x)+(c3*(x^2)), add=T, col="red")
>