Final Project

Job ID: 32359373

Budget: $30 – $250 USD

Please submit your answers as a single PDF or .docx file. This file should include everything you want me to grade, including anything you write, any numeric answers you compute, and any plots you produce. Additionally, you must submit the work you did in support of those answers; for many this will be a .R file, but you may also submit images of handwritten work, spreadsheet files, etc. Whatever work you submit should reproduce the answers you provided, but I will not grade answers that appear only in the supporting documents. Remember: you may use any computational or graphing aid that you like for this exam with the exception of another person. Do your own work.

Good luck!
1
Consider the "cabbages" data set provided with this exam; the data itself is in cabbages.csv and the docu- mentation is provided in cabbages.txt.
1. Using symbols (e.g., ?? ? = ? + ?? + ?? ? , which is the basic model for an ANOVA), write a simple linear model describing the relationship between weight of a head of cabbage and its ascorbic acid content. What do each of the symbols represent?
2. Using only basic math functions, such as sums and exponents, and simple summary statistics, such as means, and the ordinary least squares procedure, estimate the coefficients in this model from the data provided.
3. Using your software of choice, show that you have calculated the coefficients correctly.
4. Provide a figure that helps visualize the relationship between head weight and ascorbic acid in this data. This figure should look professional: include proper axis labels in words (not variable names), a
title, appropriate shapes and colors, and so on.
5. Can you improve your model by considering the cultivar and planting date of each cabbage? Using
software to estimate coefficients, compare the simpler model you wrote above with the more compli- cated model considering more information. What measures or values did you use to compare the two models? Which model is better, and why?
6. Interpret the coefficient associated with the cultivar of the head of cabbage.
7. How would you interpret the coefficients associated with the planting date? Why is there more than
one? What does each coefficient estimate mean?
2
1. Estimate your multiple regression model from 1.5 by maximum likelihood (i.e., a generalized linear model) rather than by ordinary least squares as you did before. What are the differences, if any, between your model in 1.5 and this version?
1
2. What probability distribution did you use to model your response variable, ? (ascorbic acid content)? Why do you expect this model to work—that is, what about this system led you to believe your model choice was appropriate? Explain your choice in a paragraph or so of text without referring to this particular data set.
3. Does the data from this data set support your theoretical choice? Present figures or summary statistics that support your argument.
3
Consider the melanoma data (melanoma.csv, melanoma.txt). This data is properly analyzed with what is called a proportional hazards model, but let’s use the tools we have: ignore the ‘time‘ variable and assume that the ‘status‘ variable simply reflects the status of the individual at a follow-up time, whenever that was. Let’s say we are interested in the relationship between features of a malignant melanoma (its size, operationalized as its thickness, and whether an ulcer was present or not) and whether or not the patient was alive at the time of follow-up.
1. What type of regression model is most appropriate for this question, and why?
2. Do you need to do any data management in order to fit your model? If so, what do you choose to do,
and why?
3. What predictor variables will you use in your model? Why did you choose these variables?
4. Estimate your model, present the results in a table, and interpret the results in words (a paragraph or
so).
Related categories: Data Analytics