AI Table
or a predictor
. By querying the model, we’ll predict the
rental prices of the properties based on their attributes, such as the number of
rooms, area, or neighborhood.
Make sure you have access to a working MindsDB installation, either locally or
at MindsDB Cloud.
If you want to learn how to set up your account at MindsDB Cloud, follow
this guide. Another way is to set up
MindsDB locally using
Docker or
Python.
Let’s get started.
example_db.demo_data.home_rentals
table).example_db.demo_data.home_rentals
table. Make sure you replace it with
files.home_rentals
if you connect the data as a file.rental_price
column value for all the newly added properties.
Below is the sample data stored in the example_db.demo_data.home_rentals
table.
Column | Description | Data Type | Usage |
---|---|---|---|
number_of_rooms | Number of rooms in a property [0,1,2,3] . | integer | Feature |
number_of_bathrooms | Number of bathrooms in a property [1,2] . | integer | Feature |
sqft | Area of a property in square feet. | integer | Feature |
location | Rating of the location of a property [poor, great, good] . | character varying | Feature |
days_on_market | Number of days a property has been on the market. | integer | Feature |
neighborhood | Neighborhood [alcatraz_ave, westbrae, ..., south_side, thowsand_oaks] . | character varying | Feature |
rental_price | Rental price of a property in USD. | integer | Label |
CREATE MODEL
statement and specify the
input columns used to train FROM
(features) and what we want to
PREDICT
(labels).
rental_price
column,
whose values will be predicted.
complete
, we can start making
predictions!
SELECT
statement lets you make predictions for the label
based on the chosen features.
JOIN
.