Last active
July 7, 2019 20:42
-
-
Save WillKoehrsen/b587a42555f06af9c529273871bb0bb2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def house_price_in_aus_from_model(usd_per_floor, | |
usd_per_bathroom_squared, | |
floor_count, | |
bathroom_count, | |
usd_to_aus_rate): | |
""" | |
Calculate the house price in Australian dollars from | |
a polynomial regression model | |
""" | |
house_price_in_usd = usd_per_floor * floor_count + \ | |
usd_per_bathroom_squared * bathroom_count ** 2 | |
house_price_in_usd = house_price_in_usd + expected_mean_house_price_in_usd | |
house_price_in_aud = house_price_in_usd * usd_to_aud_rate | |
return house_price_in_aud |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment