Description Format Source Examples
A data set contains 21613 obervations with 19 features plus house price. The names of the columns are given below.
id
date: Date house was sold(String)
price: Price of the sold house
bedrooms: Numer of Bedrooms
bathrooms: Numer of bathrooms
sqft_living: Square footage of the living room
sqrt_log: Square footage of the log
floors: Total floors in the house
waterfront: Whether the house has a view a waterfront(1: yes, 0: not)
view: unknown
condtion: Condition of the house
grade: unknown
sqft_above: Square footage of house apart from basement
sqft_basement: Square footage of the basement
yr_built: Built year
yr_renovated: Year when the house was renovated
zipcode: zipcode of the house
lat: Latitude coordinate
long Longitude coordinate
sqft_living15: Living room area in 2015(implies some renovations)
sqrt_lot15: Lot area in 2015(implies some renovations)
A data frame with 21613 rows and 19 variables
https://www.kaggle.com/harlfoxem/housesalesprediction
1 2 3 4 5 6 7 8 | data(kc_house_data)
#convert date in string to date in numeric value
kc_house_data[,2]=sapply(kc_house_data[,2],as.double)
train = sample(1:21613)[1:1000]
x.train = as.matrix(kc_house_data[train,c(2,4:21)]) #exclude id, house price
y.train = as.matrix(kc_house_data[train,3]) # house price
x.test = as.matrix(kc_house_data[-train,c(2,4:21)])
y.test = as.matrix(kc_house_data[-train,3])
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.