Skip to content

App Reference

The Streamlit app provides a browser-based interface to the trained Random Forest model. Users enter property characteristics via sliders and number inputs, then receive a predicted sale price.

Running the App

streamlit run app.py

Opens at http://localhost:8501 by default.

Input Fields

All inputs map directly to the 12 features the model was trained on. The order below matches the order in the interface.


Overall Quality

Input type: Slider (1–10)

Rates the overall material and finish quality of the house. This is a composite judgment score, not a specific measurement.

Score Meaning
1–2 Very Poor
3–4 Below Average
5–6 Average
7–8 Good
9–10 Excellent

Tip

This is the single most predictive feature in the model. A difference of 2 points on this scale typically moves the predicted price more than a 500 sq ft difference in living area.


Bathrooms Above Ground

Input type: Slider (1–10)

Number of full bathrooms on above-ground floors. Does not include basement bathrooms.


Year Built

Input type: Number input (0–2024)

The year construction was completed. Older properties generally predict lower prices, all else equal, reflecting depreciation.


Year Remodeled

Input type: Number input (0–2024)

The year of the most recent remodel. If no remodeling has occurred, enter the same value as Year Built.


Masonry Veneer Area

Input type: Number input (0–10,000 sq ft)

The area of masonry veneer (brick or stone facing) on the exterior. Enter 0 if none.


Above-Ground Living Area

Input type: Number input (0–10,000 sq ft)

Total finished above-ground living area in square feet. This is the primary size signal in the model.


Total Basement Area

Input type: Number input (0–10,000 sq ft)

Total square footage of basement space, finished and unfinished. Enter 0 if no basement.


First Floor Area

Input type: Number input (0–10,000 sq ft)

Square footage of the first floor only.


Total Rooms Above Grade

Input type: Number input (0–15)

Total number of rooms above ground level. Does not include bathrooms.


Fireplaces

Input type: Number input (0–15)

Number of fireplaces. Enter 0 if none.


Garage Capacity

Input type: Number input (0–15)

Number of cars the garage can accommodate. Enter 0 if no garage.


Garage Area

Input type: Number input (0–3,000 sq ft)

Total garage size in square feet. Enter 0 if no garage.


Output

Clicking Predict Sale Price passes all 12 inputs to the Random Forest model as a single feature vector and displays the predicted sale price in US dollars.

prediction = model.predict(
    np.array([[quality, bath, year, year_rem, msnv,
               livarea, bsmt, firstflr, room, fire,
               garage, garsize]])
)

The output is a point estimate — a single number representing the model's best prediction. The model does not currently return a confidence interval.

Units

The model was trained on the Ames Housing dataset where SalePrice is denominated in USD. The output reflects that currency and geographic context — it is not calibrated for other markets.