Generation

generate functionMon, 20 Mar 2023

A large agricultural company produces two species of grass and would like to know which type to grow in Northern Ontario. They would also like to know which of their three fertilizers is most effective for that grass. The company conducts an experiment in a large patch of soil in Northern Ontario. The patch is divided into 30 regions, and 5 are randomly selected for each grass/fertilizer combination. After several months, you determine the number of blades of grass per square inch in each region. The data is given in the file “Grass.csv”. HINT: type of species and type of fertilizer are given as numerical values and you must convert them to categories. What type of experiment is this?

## ## Call: ## lm(formula = grass ~ fertilizer * species, data = grass) ## ## Residuals: ## Min 1Q Median 3Q Max ## -11.979 -3.917 0.702 3.302 14.873 ## ## Coefficients: ## Estimate Std. Error t value Pr(>|t|) ## (Intercept) -19.0584 7.8839 -2.424 0.0206 ## fertilizer2 12.7062 8.6050 1.475 0.1554 ## fertilizer3 12.5899 8.5996 1.461 0.1602 ## species2 14.0992 8.5995 1.639 0.1193 ## fertilizer2:species2 5.8918 9.9617 0.591 0.5630 ## fertilizer3:species2 5.7755 9.9661 0.580 0.5697

Questions about programming?Chat with your personal AI assistant