Skip to content

ZackLarsen/lasso-regression

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Lasso Regression with UV + Notebooks

Setup

  1. Install dependencies and create the environment:
uv sync
  1. Open Jupyter in the project environment:
uv run jupyter lab

Notebook order

  1. notebooks/preprocess_train.ipynb
  2. notebooks/predict_evaluate.ipynb

Diagnostics included

  • CV diagnostics (Lasso alpha error path + learning curve) to check overfitting risk.
  • Regression plots (actual vs predicted, residuals vs predicted).
  • Feature importance plot from Lasso coefficients.
  • Optional thresholded classification metrics derived from regression outputs.
  • Calibration-style threshold sweep for threshold selection.

Configuration

  • Main configuration lives in configs/project.yaml.
  • Machine-generated outputs are written to artifacts/*.json and artifacts/*.csv.

Artifacts

  • artifacts/model.joblib — trained pipeline
  • artifacts/splits.json — train/test split indices
  • artifacts/training_summary.json — selected alpha and CV summary
  • artifacts/predictions.csv — test predictions
  • artifacts/metrics.json — RMSE/MAE/R² on test set
  • artifacts/classification_metrics.json — thresholded classification metrics

Latest experiment results

Regression metrics (test set)

Metric Value
RMSE 52.9196
MAE 42.7930
0.4714

Regression metrics table

Thresholded classification metrics (test set)

Threshold used: 140.5

Metric Value
Accuracy 0.7753
Precision 0.7083
Recall 0.8500
F1 0.7727
ROC-AUC 0.8423

Classification metrics table

Embedded report visuals

Overfitting and CV checks

CV error path Learning curve RMSE Overfitting summary table

Regression performance

Regression performance

Feature importance

Feature importance Top features table

Classification analysis

Threshold sweep Confusion matrix

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors