Docsity

Stat 665 Homework 3: Logistic Regression Applications, Assignments of Statistics

Toggle sidebar
bg1
Stat 665 (Spring 2008)
Kaizar
Homework 3
Due at the beginning of class, Monday April 21.
Aim of Homework: To apply and interpret logistic regression models for categorical responses
and either categorical or continuous expanatory variables.
Also, to select teams for the final project.
Reading: An Introduction to Categorical Data Analysis, 2nd edition: Chapter 4
Exercises:
1. Team Seleciton (0 points) You must participate in a a team with exactly two members,
exactly one of which whom should be a statistics major. You have three options for how you
get your team-mate:
(a) If you and another student have already agreed to be a partner, indicate this and list this
student’s name
(b) If you have a preference for students you’d like to work with, but have not already made
arrangements, list your preferences
(c) If you do not have any preference, indicate this and I will assign you a partner.
2. Logistic Regression with Continuous Explanatory Variables (6 points)
Agresti Exercise 4.8
3. Logistic Regression with Categorical Explanatory Variables (5 points)
Agresti Exercise 4.9, parts a-d.
4. Logistic Regression with Continuous and Categorical Explanatory Variables (5
points)
Agresti Exercise 4.22
5. Logistic Regression with Interactions (3 points)
Agresti Exercise 4.25
Possibly helpful R code for plotting:
wts=seq(from=min(crabs$weight), to=max(crabs$weight), length=100)
plot(wts, predict(inter.glm, data.frame(weight=wts, mycolor=0), type="response"),
ylim=c(0,1), type="l", xlab="Weight", ylab="Probability of Satellite", lwd=1.5)
for(i in 1:3){
lines(wts, predict(inter.glm, data.frame(weight=wts, mycolor=i), type="response"),
col=i+1, lty=i+1, lwd=1.5)
}
legend("bottomright", legend=c("Medium Light", "Medium", "Medium Dark", "Dark"),
lty=1:4, col=1:4, lwd=1.5)
1
pf2

Partial preview of the text

Download Stat 665 Homework 3: Logistic Regression Applications and more Assignments Statistics in PDF only on Docsity!

Stat 665 (Spring 2008) Kaizar

Homework 3

Due at the beginning of class, Monday April 21.

Aim of Homework: To apply and interpret logistic regression models for categorical responses and either categorical or continuous expanatory variables.

Also, to select teams for the final project.

Reading: An Introduction to Categorical Data Analysis, 2nd edition: Chapter 4

Exercises:

  1. Team Seleciton (0 points) You must participate in a a team with exactly two members, exactly one of which whom should be a statistics major. You have three options for how you get your team-mate:

(a) If you and another student have already agreed to be a partner, indicate this and list this student’s name (b) If you have a preference for students you’d like to work with, but have not already made arrangements, list your preferences (c) If you do not have any preference, indicate this and I will assign you a partner.

  1. Logistic Regression with Continuous Explanatory Variables (6 points) Agresti Exercise 4.
  2. Logistic Regression with Categorical Explanatory Variables (5 points) Agresti Exercise 4.9, parts a-d.
  3. Logistic Regression with Continuous and Categorical Explanatory Variables ( points) Agresti Exercise 4.
  4. Logistic Regression with Interactions (3 points) Agresti Exercise 4. Possibly helpful R code for plotting:

wts=seq(from=min(crabs$weight), to=max(crabs$weight), length=100) plot(wts, predict(inter.glm, data.frame(weight=wts, mycolor=0), type="response"), ylim=c(0,1), type="l", xlab="Weight", ylab="Probability of Satellite", lwd=1.5) for(i in 1:3){ lines(wts, predict(inter.glm, data.frame(weight=wts, mycolor=i), type="response"), col=i+1, lty=i+1, lwd=1.5) } legend("bottomright", legend=c("Medium Light", "Medium", "Medium Dark", "Dark"), lty=1:4, col=1:4, lwd=1.5)

  1. Summarize Logistic Regression Findings (3 points)

Write a paragraph (or two) summarizing your findings about the relationship between the presence of satellites and the weight and color of horseshoe crabs. This paragraph should be stand alone (i.e., interpretable without reading your responses to the other questions), and able to be understood by someone who understands some statistics, but has not had training in logistic regression.

  1. Relationship between the MH test and logistic regression (3 points)

Agresti Exercise 4.

  1. EXTRA CREDIT especially designed for statistics students (1 point)

(a) Consider the mean equation of a logistic regression:

π(x) =

eα+βx 1 + eα+βx^

Show that the slope of this line at a particular value of x is βπ(x)(1 − π(x)). Hint: the slope at x is the derivative of the function at x.