Question

The file P17_05.xlsx contains data on 100 consumers who drink beer. Some of them prefer light...

The file P17_05.xlsx contains data on 100 consumers who drink beer. Some of them prefer light beer, and others prefer regular beer. A major beer producer believes that the following variables might be useful in discriminating between these two groups: gender, marital status, annual income level, and age. b. Consider a new customer: male, married, income $42,000, age 47. Use the logistic regression equation to estimate the probability that this customer prefers Regular. How would you classify this person?

Individual Gender Married Income Age Beer Preference
1 1 0 $37,779 45 Regular
2 0 1 $44,955 53 Regular
3 1 0 $36,896 48 Regular
4 1 1 $70,981 45 Light
5 1 0 $38,990 36 Regular
6 1 1 $51,126 41 Light
7 0 1 $45,133 51 Light
8 1 1 $36,316 41 Light
9 1 1 $40,955 69 Regular
10 0 1 $27,280 55 Regular
11 0 1 $33,027 51 Regular
12 1 1 $63,555 62 Light
13 1 1 $64,709 70 Regular
14 1 0 $38,447 37 Light
15 1 1 $35,282 59 Regular
16 0 1 $43,468 52 Regular
17 1 0 $53,768 34 Light
18 0 1 $52,875 71 Light
19 1 0 $29,728 41 Regular
20 0 0 $30,587 36 Regular
21 0 1 $49,585 34 Light
22 1 1 $48,957 33 Light
23 1 1 $32,739 50 Regular
24 1 0 $41,057 40 Light
25 1 0 $31,916 43 Regular
26 1 0 $29,077 39 Regular
27 1 1 $58,164 30 Light
28 0 1 $30,784 52 Regular
29 1 1 $25,440 51 Regular
30 0 0 $41,779 39 Light
31 0 0 $26,598 29 Light
32 1 1 $30,081 56 Regular
33 1 1 $43,194 47 Light
34 1 0 $22,408 40 Regular
35 1 1 $42,108 26 Light
36 0 0 $40,456 42 Light
37 1 1 $47,797 49 Light
38 1 0 $43,992 53 Light
39 1 1 $41,882 54 Regular
40 1 1 $55,281 48 Light
41 1 1 $47,495 35 Light
42 0 0 $33,088 22 Light
43 0 1 $46,890 36 Light
44 0 0 $35,406 29 Light
45 0 1 $59,485 36 Light
46 1 0 $42,775 27 Light
47 0 0 $28,094 39 Regular
48 1 0 $26,004 62 Regular
49 1 0 $38,671 44 Light
50 0 1 $33,880 48 Regular
51 0 0 $43,593 27 Light
52 0 0 $27,078 45 Regular
53 1 0 $37,926 33 Light
54 1 1 $50,517 38 Light
55 0 0 $39,370 28 Light
56 0 0 $31,398 47 Regular
57 1 0 $29,293 43 Regular
58 1 0 $49,811 49 Regular
59 0 0 $38,453 43 Regular
60 0 0 $31,779 46 Regular
61 0 1 $33,700 25 Light
62 0 1 $37,263 49 Regular
63 0 1 $44,802 34 Light
64 0 1 $35,050 36 Light
65 1 1 $37,606 37 Light
66 1 0 $52,341 42 Light
67 1 1 $45,600 50 Regular
68 1 1 $36,030 55 Regular
69 0 1 $44,558 31 Light
70 1 1 $34,391 60 Regular
71 1 1 $43,741 54 Regular
72 0 0 $36,821 32 Light
73 1 1 $51,578 45 Light
74 1 0 $23,234 31 Regular
75 0 1 $48,259 32 Light
76 0 1 $46,273 56 Light
77 1 1 $42,404 30 Light
78 0 0 $41,391 54 Light
79 0 1 $45,610 38 Light
80 1 1 $47,667 87 Regular
81 1 1 $40,261 31 Light
82 1 0 $46,626 46 Light
83 0 1 $55,608 43 Light
84 1 1 $35,678 64 Regular
85 0 0 $50,154 40 Light
86 1 0 $34,575 57 Regular
87 0 0 $30,841 24 Light
88 1 0 $20,945 42 Regular
89 1 0 $38,176 40 Regular
90 1 0 $28,513 34 Regular
91 0 1 $51,094 46 Regular
92 1 1 $40,582 66 Regular
93 1 0 $32,493 63 Regular
94 0 1 $36,451 44 Regular
95 0 1 $42,051 58 Regular
96 0 0 $26,186 38 Regular
97 1 1 $24,302 46 Regular
98 0 0 $39,923 58 Regular
99 0 1 $39,942 21 Light
100 1 0 $33,553 48 Regular

Homework Answers

Answer #1

a) I have performed the logistic regression in R. Here is the code:

R Code:

beer<-read.csv("beer.csv")
logitmod<-glm(Beer.Preference~Gender + Married + Income + Age, family="binomial",data = beer)
summary(logitmod)

Output:

Coefficients:
Estimate Std. Error z value Pr(>|z|)
(Intercept) 6.819e-01 1.931e+00 0.353 0.724
Gender 7.779e-01 7.166e-01 1.085 0.278
Married -1.697e-01 7.945e-01 -0.214 0.831
Income -2.785e-04 6.334e-05 -4.396 1.10e-05 ***

B) For prediction, R Code:

person<-data.frame(Gender=1,Married=1,Income=42000,Age=45)
predict(logitmod,person,type="response")

Output: 0.466

As the output is the probability to predict the probability of Event '1' = 'Regular'. Hence, as p-value<0.5, we can say that the person prefers Light beer.

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
Please compute the value, upper control limit, and lower control limit for the x-bar chart, r-bar...
Please compute the value, upper control limit, and lower control limit for the x-bar chart, r-bar chart, p chart, and np chart. Sample # Observations Defects 1 44 49 44 44 40 0 2 42 46 51 51 42 2 3 45 45 49 49 46 2 4 40 39 42 42 47 7 5 44 51 53 53 44 2 6 41 44 43 43 46 8 7 40 44 46 46 48 3 8 54 49 48 48...
2a. Describe the sample and population you are studying. I am studying customers' satisfaction level with...
2a. Describe the sample and population you are studying. I am studying customers' satisfaction level with their car insurance plan. 2b. Calculate the sample mean and sample standard deviation for your variable. Keep at least four decimal places. 2c. Calculate the standard error and the margin of error for a 90% confidence interval. Keep at least four decimal places. Data: 36 18 66 43 28 39 47 40 24 46 48 57 36 58 39 62 43 65 74 36...
What percent of undergraduate enrollment in coed colleges and universities in the United States is male?...
What percent of undergraduate enrollment in coed colleges and universities in the United States is male? A random sample of 50 such institutions give the following data. Percent Males Enrolled in Coed Universities and Colleges 44 41 41 41 38 50 48 31 52 28 50 42 71 37 43 38 53 51 52 50 47 46 49 50 39 38 58 64 40 54 32 46 48 34 54 48 40 46 42 41 46 42 41 46 54...
How Democratic is Georgia? County-by-county results are shown for a recent election. For your convenience, the...
How Democratic is Georgia? County-by-county results are shown for a recent election. For your convenience, the data have been sorted in increasing order (Source: County and City Data Book, 12th edition, U.S. Census Bureau). Percentage of Democratic Vote by Counties in Georgia 31 33 34 34 35 35 35 36 38 38 38 39 40 40 40 40 41 41 41 41 41 41 41 42 42 43 44 44 44 45 45 46 46 46 46 47 48 49...
The Whitcomb Company manufactures a metal ring for industrial engines that usually weighs about 50 ounces....
The Whitcomb Company manufactures a metal ring for industrial engines that usually weighs about 50 ounces. A random sample of 50 of these metal rings produced the following wights (in ounces). 51 53 56 50 44 47 53 53 42 57 46 55 41 44 52 56 50 57 44 46 41 52 69 53 57 51 54 63 42 47 47 52 53 46 36 58 51 38 49 50 62 39 44 55 43 52 43 42 57...
Refer to the Body Measurements Female Data Set and Body Measurements Male Data Set found in...
Refer to the Body Measurements Female Data Set and Body Measurements Male Data Set found in StatDisk (Elementary Stats 12th Edition, sets #1a and 1b) and use columns 5 for HDL. Use a .05 significance level to test the claim that men and women have the same mean HDL level (High-Density Lipoprotein) female 74 56 70 40 67 96 43 80 77 41 23 76 39 52 38 37 57 81 37 50 73 61 33 41 60 62 67...
Q1. A clinical trial is run to assess the effects of different forms of regular exercise...
Q1. A clinical trial is run to assess the effects of different forms of regular exercise on HDL levels in persons between the ages of 18 and 29. Participants in the study are randomly assigned to one of three exercise groups - Weight training, Aerobic exercise, or Stretching/Yoga – and instructed to follow the program for 8 weeks. Their HDL levels are measured after 8 weeks and are summarized below. Weight Training Aerobic Exercise Stretching/Yoga 48 38 56 49 41...
How Democratic is Georgia? County-by-county results are shown for a recent election. For your convenience, the...
How Democratic is Georgia? County-by-county results are shown for a recent election. For your convenience, the data have been sorted in increasing order (Source: County and City Data Book, 12th edition, U.S. Census Bureau). Percentage of Democratic Vote by Counties in Georgia 31 33 34 34 35 35 35 36 38 38 38 39 40 40 40 40 41 41 41 41 41 41 41 42 42 43 44 44 44 45 45 46 46 46 46 47 48 49...
The answers are provided. Please provide an explanation/machanism to support the answers. Questions 1, 3, 13,...
The answers are provided. Please provide an explanation/machanism to support the answers. Questions 1, 3, 13, 14, 19, 21, 25, 27, 30, 32, 33, 34, 37, 38, 39, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 61, 62, 63 and 65. (I know it's a lot, but please do as many as you are willing to. Thank you! Here is the link to the document: http://www.kau.edu.sa/Files/0008904/files/41686_g.pdf
Using the data set (link below), please calculate a one-way chi-square tests for President Trump approval...
Using the data set (link below), please calculate a one-way chi-square tests for President Trump approval rating for the first years in office. Specifically run chi-square on the "Approving" column. This is the information provided. Approving Disapproving Unsure/NoData 39 55 6 37 57 6 35 60 5 36 59 5 35 59 6 37 56 7 38 57 5 38 56 6 38 58 4 35 60 5 36 58 6 37 57 6 38 56 6 37 58 5...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT