Skip to content

Amir-Shamsi/cost-prediction-LR

Repository files navigation

Insurance Cost Prediction with Linear Regression

BSD Licence Project Initiator Repo Size made-with-Markdown GitHub followers

Implemetation of cost prediction for medical insurance using linear regression with python.

Dataset

you can see the data set here:

  age         sex             bmi             children             smoker             region             charges      
19 female 27.9 0 yes southwest 16884.924
18 male 33.77 1 no southeast 1725.5523
28 male 33 3 no southeast 4449.462
33 male 22.705 0 no northwest 21984.47061
32 male 28.88 0 no northwest 3866.8552
31 female 25.74 0 no southeast 3756.6216
46 female 33.44 1 no southeast 8240.5896
37 female 27.74 3 no northwest 7281.5056
... ... ... ... ... ... ...

overview of what our dataset is.

Data visualization

you can analyze data using the following code:

from predictor import InsuranceCostPredictor

icp = InsuranceCostPredictor('dataset/insurance.csv')
icp.analyze(hue='smoker', based_on=['age', 'bmi', 'smoker', 'charges'])

see the example file to undrestand exactly how to use it.

Libraries

to implement this project this libraries have been used:

  • pandas
  • matplotlib
  • sklearn
  • seaborn

Installation

  1. clone project using this code in you shell:

    git clone https://github.com/Amir-Shamsi/insurance-cost-prediction-LR/.git
  2. install requirements

    pip install -r requirements.txt
  3. Done 👾

About

Insurance cost prediction using Linear Regression

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages