Agriculture Reference
In-Depth Information
200
150
100
50
95% Cl
Fitted values
Yield
0
0
100
200
300
nrate
Figure 10.14
Graph of onion yield with a quadratic curve and confidence intervals.
makes sense. You would expect an increase up to a point and then
yields would drop of because of overfertilization.
Stata also offers the nl command that allows the analysis of non-
linear regression with any type of function. There are several built-in
functions with this command that can be analyzed because they are so
widely used. They include exponential regression with one asymptote,
logistic function (symmetric sigmoid shape), and Gompertz function
(asymmetric sigmoid shape).
Open the dataset Barley Yield.dta, which is a dataset measuring total
dry matter based on days after seed drilling (Clewer and Scarisbrick,
2001, p. 99). Enter the following command and see the results:
nl log3: yield days
(obs = 19)
Iteration 0: residual SS = 21.47574
Iteration 1: residual SS = 7.036482
Iteration 2: residual SS = 6.362144
Iteration 3: residual SS = 6.354819
Iteration 4: residual SS = 6.354655
Iteration 5: residual SS = 6.354652
Iteration 6: residual SS = 6.354652
Iteration 7: residual SS = 6.354652
Source | SS df MS
----------+-------------------------------Number of obs = 19
Model |1757.32536 3 585.775119 R-squared = 0.9964
Residual |6.35465168 16 .39716573 Adj R-squared = 0.9957
----------+------------------------------ Root MSE = .6302109
Total |1763.68001 19 92.8252637 Res. dev. = 33.10988
 
Search WWH ::




Custom Search