Question: The data set in alcohol contains information on a sample of men in the United States. Two key variables are self-reported employment status and alcohol
The data set in alcohol contains information on a sample of men in the United States. Two key variables are self-reported employment status and alcohol abuse (along with many other variables). The variables employ and abuse are both binary, or indicator, variables: they take only the value zero and one.
(1) [12 marks] To check the percentage of the men in the sample report abusing alcohol, we have the following results. ## [1] 0.09916514 Write out the R code to generate result above.
(2) [12 marks] To check the employment rate, we have the following results. ## [1] 0.8981877
Write out the R code to generate result above.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
