Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Use R Program a) [8 points] Create a function named all_loan_offers that satisfies the following requirements: Arguments: - A data frame that stores the income,

Use R Program

image text in transcribed

a) [8 points] Create a function named all_loan_offers that satisfies the following requirements: Arguments: - A data frame that stores the income, criminal record, and the number of years in the present job for all loan applicants. You can use a name of your choice for the data frame, but the column names must be income, c_record, and years. - Output: The updated version of the inputted data frame which has a new column titled "decision". "decision" is a categorical column whose elements can take any values of "Admit" or "Reject". Please note that the function must return the updated data frame not the decision vector. b) [1 point] Please assume that the following table shows the information of four loan applicants. Save the information in the above table in a data frame named applicants_info. Name the columns income, c_record, and years. c) [1 point] Run your function using applicants_info as its input. You should see the updated applicants_info including the decision column of "Reject" "Admit" "Reject" "Admit" as the function's output

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Beginning C# 5.0 Databases

Authors: Vidya Vrat Agarwal

2nd Edition

1430242604, 978-1430242604

More Books

Students also viewed these Databases questions

Question

Account for the disposition of property, plant, and equipment?

Answered: 1 week ago

Question

Always mention the specifi c problem the customer faced.

Answered: 1 week ago