200 likes | 348 Views
Part III The General Linear Model. Multiple Explanatory Variables Chapter 12 Multiple Regression. Introduction. GLM, one explanatory: Regression: t-test/ANOVA: GLM, multiple explanatory: Multiple Regression Multi-way ANOVA ANCOVA .
E N D
Part IIIThe General Linear Model. Multiple Explanatory VariablesChapter 12 Multiple Regression
Introduction • GLM, one explanatory: • Regression: • t-test/ANOVA: • GLM, multiple explanatory: • Multiple Regression • Multi-way ANOVA • ANCOVA
GLM | Multiple RegressionPcorn example…again • Example 9.3.1 from Snedecorand Cochran (1989) • Interested in the relationship between: • Phosphorus content of corn and phosphorus (organic and inorganic)levels in soil samples.
1. Construct Model Verbal: Plant available phosphorus depends on the amount of both organic and inorganic soil phosphorus Graphical:
1. Construct Model Verbal: Plant available phosphorus depends on the amount of both organic and inorganic soil phosphorus Graphical:
1. Construct Model Formal: • Start with individual explanatory variables:
1. Construct Model Formal: • Now we construct a model with both explanatory variables • is the rate of change in phosphorus content of corn relative to rate of change of inorganic phosphorus, adjusted for effects of organic phosphorus. is the opposite.
1. Construct Model Partial Regression
1. Construct Model Formal: • Now we construct a model with both explanatory variables • is the rate of change in phosphorus content of corn relative to rate of change of inorganic phosphorus, adjusted for effects of organic phosphorus. is the opposite. • Together, and parameters describe a plane through the data points
1. Construct Model Formal:
1. Construct Model Formal: • Finally, we add an interaction term Investigate potential interactive effects on the response variable
2. Execute analysis mr <- lm(Pcorn~ioP+oP+ioP*oP, data=corn) The overall mean is: mean(Pcorn) = = 76.18 ppm The regression equation for ioP is: Pcorn = 62.6 + 1.23 ioP The regression equation for oP is: Pcorn = 65.4 + 0.262 oP The regression equation for both variables: Pcorn= 45.92 + 0.3278 oP+ 5.304 ioP+ 0.0830 ioP*oP
3. Evaluate Model • Straight line model ok? • Errors homogeneous? • Errors normal? • Errors independent?
State the population and whether the sample is representative. • Decide on mode of inference. Is hypothesis testing appropriate? • State HA / Ho pair, test statistic, distribution, tolerance for Type I error. • Separate statement for each explanatory variable
State the population and whether the sample is representative. • Decide on mode of inference. Is hypothesis testing appropriate? • State HA / Ho pair, test statistic, distribution, tolerance for Type I error. • Separate statement for each explanatory variable var
7. ANOVA n = 17
8. Recompute p-value if necessary. • Assumptions met, skip 9. Declare decision about model terms. • First and foremost, there is interaction (p = 0.035) • Reject Ho: • Complex result, so present ANOVA table (Type III SS)
10. Report and interpret parameters of biological interest. • Present parameter estimates along with CL • Pcorn= 45.92 + 0.3278 oP+ 5.304 ioP+ 0.0830 ioP*oP • Organic and inorganic soil phosphorus have interactive effects on phosphorus content of corn. If we wish to look at the effects of soil phosphorus on corn phosphorus content we need to know both organic and inorganic concentrations in the soil. We need to use the interaction term to compute the expected levels of corn phosphorus.