Create a logistic regression model using glm to predict

Assignment Help Computer Engineering
Reference no: EM133719142

Assignment: R Programming Worksheet

In an R Markdown document, write the appropriate code in an r chunk (use ```{r} to start a chunk and ``` to end it) and answer the questions in the normal white space on the document. R markdown will automatically print the plots when you knit the markdown document, so you don't need to save them anywhere else.

Required packages: tidyverse, jtools, kableExtra

Problem 1: Linear regression, model 1

1. Create a new object called employed by filtering (dplyr method) the data to include only people who are employed (in government, private company/organization, or self-employed).

2. Create a linear model that predicts income as a function of age, sex, and origin region for the dataframe created in I1.

3. Use summ() (from the jtools package). What is the reference category for this model?

4. What do the results of summ() tell you?

5. Use plot_summs() to print a plot of the variables in your model.

Problem 2: Linear regression, model 2

1. Create a linear model that predicts income as a function of age, sex, and language at home for employed people in the data.

2. Use summ(). What is the reference category for this model?

3. What do the results of summ() tell you?

4. Use plot_summs() to print a plot of the variables in your model.

Problem 3: Linear regression, model 3

1. Create a linear model that predicts income as a function of age, sex, language at home, and education for employed people in the data.

2. Use summ(). What is the reference category for this model?

3. What do the results of summ() tell you?

4. Use plot_summs() to print a plot of the variables in your model.

5. Instead of the education variable, run the same model with the binary "completed_college" variable.

Problem 4: Analysis

1. Look back at your results from the linear models. Look back at the expectations you wrote down in Homework. Which of your hypotheses/expectations seemed accurate? Did you find any surprises? Based on these linear models, would you say that differences in income among these groups are mainly based on age differences among the groups, on differences in education levels, or on differences in each groups' migration background and/or unique culture? Explain. Use specific examples of what the estimates (Est.) from these different models mean (focus on estimates with p values <= 0.05).

Problem 5: Logistic regression, model 1

1. Use the dplyr method (pipeline) to calculate what percentage of males and females in the data are self-employed

2. Since males have a much higher percentage of self-employment, create a new data frame by filtering to include only males. This might help isolate whether differences in culture, age, or education are better predictors of self-employment.

3. Set the reference categories for the language_at_home, origin_region, and education variables in your new data frame. I suggest setting them for the groups who you expect to have the lowest levels of self-employment.

4. Create a logistic regression model using glm(family = "binomial") to predict self-employment as a function of age and origin region.

5. Use summ() with exp = TRUE. What is the reference category for your model?

6. What do the results of summ() mean?

7. Use plot_summs() to print a plot of the variables in your model.

Problem 6: Logistic regression, model 2

1. Create a logistic regression model to predict self-employment as a function of age, language at home, and education.

2. Use summ() with exp = TRUE. What is the reference category for your model?

3. What do the results of summ() mean?

4. Use plot_summs() to print a plot of the variables in your model.

Problem 7: Analysis

1. Look back at your results from the logistic/binomial models in Problems V and VI. Look back at your expectations about what predictor variables would affect self-employment from Homework. Which of your hypotheses/expectations seemed accurate? Did you find any surprises? Based on these logistic models, would you say that differences in self-employment among males from these groups are mainly based on age differences among the groups, on differences in education levels, or on differences in each groups' migration background and/or unique culture? Explain what the models tell you about the relative effects of the predictor variables on self-employment. Pay particular attention to the odds ratios (exp(Est.)) with p values < = 0.05.

Reference no: EM133719142

Questions Cloud

Explain how your selected presidents worked to improve : Explain how your selected presidents worked to improve the United States economically and socially. Give at least one example of each president.
Discuss the benefits of including transgender individuals : Discuss benefits of including transgender individuals in military. Mention enhanced diversity, increased talent pool, and improved morale among service members.
How would you compare your candidacy for the two positions : Assess how would you compare your candidacy for these two positions as well as how would you bridge your academic qualification or skill gaps?
How philosophy and practice of political authority change : Drawing upon evidence from the readings answer the prompt: How did the philosophy and practice of political authority change from Antiquity to Renaissance?
Create a logistic regression model using glm to predict : Create a logistic regression model using glm(family = binomial) to predict self-employment as a function of age and origin region.
What is the default setting and how does david wallace : What is the default setting and how does David Wallace (Kenyon Commencement Speech) believe Academic Education influences a default setting?
Develop a dynamic online system that allows users : ITBP 321 Web App Development Lab - develop a dynamic online system that allows users to interact with a database through a secure login page.
What do you see as most important things that parents can do : CHFD 308 American Military University- What do you see as the most important things that parents can do to help their children at this point in their lives?
How can the company improve groupawareness in the company : How can the company improve groupawareness in the company and State the process of using a microcosm group to address organization-wide issues.

Reviews

Write a Review

Computer Engineering Questions & Answers

  Mathematics in computing

Binary search tree, and postorder and preorder traversal Determine the shortest path in Graph

  Ict governance

ICT is defined as the term of Information and communication technologies, it is diverse set of technical tools and resources used by the government agencies to communicate and produce, circulate, store, and manage all information.

  Implementation of memory management

Assignment covers the following eight topics and explore the implementation of memory management, processes and threads.

  Realize business and organizational data storage

Realize business and organizational data storage and fast access times are much more important than they have ever been. Compare and contrast magnetic tapes, magnetic disks, optical discs

  What is the protocol overhead

What are the advantages of using a compiled language over an interpreted one? Under what circumstances would you select to use an interpreted language?

  Implementation of memory management

Paper describes about memory management. How memory is used in executing programs and its critical support for applications.

  Define open and closed loop control systems

Define open and closed loop cotrol systems.Explain difference between time varying and time invariant control system wth suitable example.

  Prepare a proposal to deploy windows server

Prepare a proposal to deploy Windows Server onto an existing network based on the provided scenario.

  Security policy document project

Analyze security requirements and develop a security policy

  Write a procedure that produces independent stack objects

Write a procedure (make-stack) that produces independent stack objects, using a message-passing style, e.g.

  Define a suitable functional unit

Define a suitable functional unit for a comparative study between two different types of paint.

  Calculate yield to maturity and bond prices

Calculate yield to maturity (YTM) and bond prices

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd