Question: I need the code to create the correct output Scenario You are a data analyst working for a real estate company. You have access to

I need the code to create the correct output
Scenario
You are a data analyst working for a real estate company. You have access to a large set of historical data that you can use to analyze relationships between different attributes of a house (such as square footage or the number of bathrooms)and the houses selling price. You have been asked to create different regression models to predict sale prices for houses based on critical variable factors. These regression models will help your company set better prices when listing a home for a client. Setting better prices will ensure that listings can be sold within a reasonable amount of time.
There are several variables in this data set, but you will be working with the following important variables:
Price =Sale price of the home
bedrooms =Number of bedrooms
bathrooms =Number of bathrooms
sqft_living =Size of the living area in sqft
sqft_above =Sise of upper level in sqft
age =Age of the home
appliance_grade =Measure of craftsmanship and the quality of materials used to build the home
crime =Crime rate per 100,000people
backyard =Home has a backyard (backyard=1)or not (backyard=0)
school_rating =Average rating of schools in the area
view =Home backs out to a lake (view=2),backs out to trees (view=1),or backs out to a road (view=0)
housing -read.csv(file="housing_v2.csv",header=TRUE, sep=",")
# converting appropriate variables to factors
housing -within(housing,{
view -factor(view)
backyard -factor(backyard)
})
# number of columns
ncol(housing)
# number of rows
nrow(housing)
23
2692
 I need the code to create the correct output Scenario You

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!