Lab 4 Instructions

BSTA 513/613

Due: May 30, 2024 at 11pm
Author

Nicky Wakim

Modified

May 28, 2024

Note

This lab looks short, but there is a lot of work here!!

1 Directions

You can download the .qmd file for this lab here.

The above link will take you to your editing file. Please do not remove anything from this editing file!! You will only add your code and work to this file.

1.1 Purpose

The purpose of this lab is to fit a multiple logistic regression model and practice how we would interpret our results for this study.

1.2 Grading

This lab is graded out of 12 points. The TAs will go through and grade your lab. They will make sure each section is complete and will follow the rubric below. I have instructed them that completion and clear effort is all that is needed to receive 100%. Nicky will go through the labs to give you feedback.

1.2.1 Rubric

4 points 3 points 2 points 1 point 0 points
Formatting Lab submitted on Sakai with .html file. Answers are written in complete sentences with no major grammatical nor spelling errors. With little editing, the answer can be incorporated into the project report. Lab submitted on Sakai with .html file. Answers are written in complete sentences with grammatical or spelling errors. With editing, the answer can be incorporated into the project report. Lab submitted on Sakai with .html file. Answers are written in complete sentences with major grammatical or spelling errors. With major editing, the answer can be incorporated into the project report. Lab submitted on Sakai with .html file. Answers are bulletted or do not use complete sentences. Lab not submitted on Sakai with .html file.
Code/Work All tasks are directly followed or answered. This includes all the needed code, in code chunks, with the requested output. All tasks are directly followed or answered. This includes all the needed code, in code chunks, with the requested output. In a few tasks, the code syntax or output is not quite right. Most tasks are directly followed or answered. This includes all the needed code, in code chunks, with the requested output. Some tasks are directly followed or answered.This includes all the needed code, in code chunks, with the requested output. In a few tasks, the code syntax or output is not quite right. More than a quarter of the tasks are not completed properly.
Reasoning* Answers demonstrate understanding of research context and investigation of the data. Answers are thoughtful and can be easily integrated into the final report. Answers demonstrate understanding of research context and investigation of the data. Answers are thoughtful, but lack the clarity needed to easily integrate into the final report. Answers demonstrate some understanding of research context and investigation of the data. Answers are fairly thoughtful, but lack connection to the research. Answers demonstrate some understanding of research context and investigation of the data. Answers seem rushed and with minimal thought. Answers lack understanding of research context and investigation of the data. Answers seem rushed and without thought.

*Applies to questions with reasoning

2 Lab activities

Note

I have left it up to you to load the needed packages for this lab.

2.1 Restate research question

Task

Please restate your research question below using the provided format (1 sentence). You can change the wording if you’d like, but please make sure it is still clear. It’s repetitive, but it helps me contextualize my feedback as I look through your lab.

In this study, we will investigate the association between food insecurity and ________.

2.2 Build your model

This lab is very open-ended. You will need to build a model for your outcome. We discussed prediction modeling in Lesson 15. (We covered everything you will need in class even though we did not finish my slides.) We discussed association modeling in BSTA 512/612.

You may either use LASSO regression OR Purposeful model selection to build a model. I highly suggest picking the model selection strategy based on your desired learning objective. LASSO will help stretch your R coding and machine learning skills. Purposeful model selection will allow you to cement certain concepts that we learned within 512/612 and 513/613.

I will not be taking you through step-by-step. Please follow my work from Lesson 15 in 513/613 or from Lab 4 in 512/612.

2.3 Assess your model fit

Check if your model fits the data well (Hosmer-Lemeshow test). Calculate the ROC-AUC of your model.

2.4 Perform model diagnostics

Check your diagnostic plots and cutoffs (change in Pearson residuals, change in coefficients, and leverage) to identify and investigate any influential or outlier observations. Are these observations feasible?