Skip to content

Kritank07/Predicting-Insurance-Charges-Using-Machine-Learning

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Predicting-Insurance-Charges-Using-Machine-Learning

This project predicts individual insurance charges using a Random Forest Regressor model. The model takes features like age, BMI, number of children, smoking status, sex, and region to estimate medical insurance costs.

Features Used

  1. Numerical: age, bmi, children
  2. Categorical: sex, smoker, region

Dataset

The dataset used is the popular Insurance Dataset from Kaggle.

Requirements

  1. Numpy
  2. Pandas
  3. scikit-learn
  4. joblib

How to Run

  1. Ensure insurance.csv is in the project folder.
  2. Run the main script:
  3. If the model does not exist, it will train the model and save it as model.pkl and pipeline.pkl.
  4. If the model already exists, it will load the model and run inference on test.csv.
  5. Output predictions will be saved to output.csv with columns:
  6. predicted_charges → model predictions
  7. actual_charges → actual charges (from test set)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages