A reproducible portfolio of applied data-science work, centered on clear problem framing, leakage-resistant evaluation, source provenance, and automated verification.
Visual intuition: the model can inspect structure, condition, quality, garage, and architectural signals, but never the construction year it is asked to infer.
| If you want to... | Go to |
|---|---|
| See the question and holdout result | Featured case study |
| Inspect the figures behind the score | Read the evidence |
| Reproduce the analysis | Reproduce |
| Review the leakage and data boundaries | Design decisions · Dataset notes |
| Read the web presentation | Published case study |
| Cite or extend the work | CITATION.cff · Contributing |
Can structural, condition, quality, garage, architectural, and transaction attributes identify homes built before 1980—without giving the model the build year?
The selected random forest is trained on 80% of 22,913 property records and evaluated on a fixed, stratified 20% holdout. yrbuilt, before1980, and the parcel identifier are explicitly removed from the model features.
| Holdout metric | Result |
|---|---|
| Accuracy | 92.36% |
| Balanced accuracy | 92.13% |
| F1 | 0.9384 |
| ROC-AUC | 0.9768 |
flowchart LR
A["22,913 property records"] --> B["Validate source and schema"]
B --> C["Remove year, target, and parcel ID"]
C --> D["Fixed stratified 80/20 split"]
D --> E["Train and compare candidates"]
E --> F["Evaluate once on holdout"]
F --> G["Metrics, figures, and case study"]
Read the complete case study, inspect the generated metrics, or open the published summary.
python -m venv .venv
.\.venv\Scripts\Activate.ps1
python -m pip install -r requirements-dev.txt
python -m unittest discover -s tests -v
python -m src.property_age_model --output reports/figures
ruff check .
ruff format --check .The default analysis downloads its CSV directly from the upstream source. To use an existing local copy:
python -m src.property_age_model --data data/dwellings_ml.csvanalysis/ narrative Quarto case study
src/ reusable data loading, validation, modeling, and reporting
tests/ offline regression tests with synthetic data
reports/figures/ deterministic holdout metrics and visual artifacts
docs/ concise GitHub Pages presentation
DATASET.md source, scope, licensing, and redistribution notes
- Raw source data is not committed; the upstream repository does not declare a dataset license.
- Direct target leakage (
yrbuilt) and high-cardinality identity (parcel) are excluded in one tested feature boundary. - Multiple metrics accompany accuracy because the target is moderately imbalanced.
- A random forest is preferred over a marginally more accurate gradient-boosting experiment because it offers a simpler, inspectable feature-importance story for this portfolio case study.
- Report figures and
metrics.jsonare generated by the same code exercised in CI.
The code and original documentation in this repository are licensed under the MIT License. Dataset terms remain with the upstream source described in DATASET.md.
For help reproducing the case study, see SUPPORT.md. Proposed changes should follow CONTRIBUTING.md, and sensitive reports should use the process in SECURITY.md.



