@justinholman/

# SellingPriceEstimates

## Generate your own selling price estimates with python code

Files
• main.py
main.py
```1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
```
```print("Hello World...I mean Adv Stats students.")
print("Here are selling price estimates using the crummy model that was on page 2 of Exam 1. And I'm using the properties from page 1 of Exam 1. Remember Exam 1?")

exam1_properties = [["Central",2,1,856],
["Minnequa",3,2,763],
["Northridge",3,3,2246],
["Northside",4,2,2078],
["Regency",5,3,2112],
["Sunset",3,2,1618],
["Belmont",2,1,875],
["Eastside",5,2,1740]]

coeff1 = 30.558
coeff2 = 30464.688
coeff3 = 1236
yintercept = -11605.478

print('\r'+ "My y-hat equation looks like this:")
print("y^ = " + str(coeff1) + "*x1 + " + str(coeff2) + "*x2 + " + str(coeff3) + "*x3 + (" + str(yintercept) + ")")
print("where x1 = SqFt, x2 = Baths, x3 = Beds" + '\r')

# Here's a loop!!
for i in range(0,len(exam1_properties)):
beds = exam1_properties[i][1]
baths = exam1_properties[i][2]
sqft = exam1_properties[i][3]
estsellprice = coeff1*sqft + coeff2*baths + coeff3*beds + (yintercept)
print(exam1_properties[i][0] + ": \$" + str(round(estsellprice,2)))

print(" ")
print("Now it's your turn. :)" + '\r')
print("Your assignment is to modify this program (in your own workspace, preferably here on repl.it) so it produces selling price estimates using your final model from Exam 1. Have fun!"+ '\r')
print('\r'+"Peace out," )
print("JH")```
Fetching token