Homework 3

Due: 2024-02-13, 11:59pm

Submission instructions

For this homework you should submit a ZIP archive containing:

  • A single document with the answers to all the following items in HTML format only. Make sure you include plain English blocks in between the code, and its output to interpret what R is giving you.
  • Code file used to generate the answers (RMD format). There should be comments in the code blocks.

  • Jupyter notebook (IPYNB) is also acceptable.
  • Please remember to mix your comments with code and output.
  • Do not forget acknowledgements.

In this homework we will practice working with factors.

1. Cauline leaf number (50%)

Use the Burghardt data, and select the cauline leaf number (Cauline.leaf.num) as the primary trait for this exercise. The Arabidopsis plant forms a rosette, and then there is a stem that comes above it. The cauline leaf number is the number of leaves on that stem.

  • Select the data for the hua2-3 and hua2-3 FRI genotypes. You will have data for a 2x2 factorial experiment. Now calculate the mean cauline leaf number for both genotypes in both vernalization conditions.
  • Using only these mean numbers, main effect of the FRI genotype ignoring vernalization. (Do not use lm for this.) Use the definition of a main effect.
  • Using only these mean numbers, calculate the interaction effect of genotype and vernalization. (Do not use lm for this.) Use the definition of an interaction effect.
  • Verify that your numbers are correct using lm.

2. Contrasts (50%)

Use the same dataset as above. Select all six genotypes for this exercise, and the cauline leaf number trait.

  • Calculate the mean trait for all six genotypes when the plants were not vernalized.
  • For this experiment (with six genotypes), there is no natural reference genotype. Using the mean trait values, calculate the main effect of each genotype defined as the difference between the mean trait for that genotype compared with the mean of all six genotype means. (Use the definition alone, and arithmetic; no other functions.)
  • Change your options to use contr.sum as the contrasts function. Now use lm to calculate the main effect of each genotype. One genotype level will be left out of the lm output. What is the main effect of that level?

3. Acknowledgements

Cite resources or individuals helping you.