TELECOM CUSTOMER CHURN PREDICTION 📈
Did you know that attracting a new customer costs five times as much as keeping an existing one?

linkcode
Content
Introduction
What is Customer Churn?
How can customer churn be reducded?
Objectives
Loading libraries and data
Undertanding the data
Visualize missing values
Data Manipulation
Data Visualization
Data Preprocessing
Standardizing numeric attributes
Machine Learning Model Evaluations and Predictions
KNN
SVC
Random Forest
Logistic Regression
Decision Tree Classifier
AdaBoost Classifier
Gradient Boosting Classifier
Voting Classifier
Q- and this my Code here 

import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
import seaborn as sns


path="data/raw/data.csv"
df=pd.read_csv(path)



Next 

## Dataset Information

The dataset includes the following key details:

- **Customers who left within the last month**:
  - Column: `Churn`
  
- **Services that each customer has signed up for**:
  - Phone
  - Multiple lines
  - Internet
  - Online security
  - Online backup
  - Device protection
  - Tech support
  - Streaming TV and movies

- **Customer account information**:
  - How long they’ve been a customer
  - Contract type
  - Payment method
  - Paperless billing
  - Monthly charges
  - Total charges

- **Demographic information about customers**:
  - Gender
  - Age range
  - Whether they have partners
  - Whether they have dependents

Next 


Df.shape
((7043, 21)


Next 

df.info()



<class 'pandas.core.frame.DataFrame'>
RangeIndex: 7043 entries, 0 to 7042
Data columns (total 21 columns):
 #   Column            Non-Null Count  Dtype  
---  ------            --------------  -----  
 0   customerID        7043 non-null   object 
 1   gender            7043 non-null   object 
 2   SeniorCitizen     7043 non-null   int64  
 3   Partner           7043 non-null   object 
 4   Dependents        7043 non-null   object 
 5   tenure            7043 non-null   int64  
 6   PhoneService      7043 non-null   object 
 7   MultipleLines     7043 non-null   object 
 8   InternetService   7043 non-null   object 
 9   OnlineSecurity    7043 non-null   object 
 10  OnlineBackup      7043 non-null   object 
 11  DeviceProtection  7043 non-null   object 
 12  TechSupport       7043 non-null   object 
 13  StreamingTV       7043 non-null   object 
 14  StreamingMovies   7043 non-null   object 
 15  Contract          7043 non-null   object 
 16  PaperlessBilling  7043 non-null   object 
 17  PaymentMethod     7043 non-null   object 
 18  MonthlyCharges    7043 non-null   float64
 19  TotalCharges      7043 non-null   object 
 20  Churn             7043 non-null   object 
dtypes: float64(1), int64(2), object(18)
memory usage: 1.1+ MB
Here’s a table that classifies the features of the DataFrame into **numerical** and **categorical**:

| Feature            | Type         | Category         |
|--------------------|--------------|------------------|
| `customerID`        | Object       | Categorical      |
| `gender`            | Object       | Categorical      |
| `SeniorCitizen`     | Int64        | Numerical        |
| `Partner`           | Object       | Categorical      |
| `Dependents`        | Object       | Categorical      |
| `tenure`            | Int64        | Numerical        |
| `PhoneService`      | Object       | Categorical      |
| `MultipleLines`     | Object       | Categorical      |
| `InternetService`   | Object       | Categorical      |
| `OnlineSecurity`    | Object       | Categorical      |
| `OnlineBackup`      | Object       | Categorical      |
| `DeviceProtection`  | Object       | Categorical      |
| `TechSupport`       | Object       | Categorical      |
| `StreamingTV`       | Object       | Categorical      |
| `StreamingMovies`   | Object       | Categorical      |
| `Contract`          | Object       | Categorical      |
| `PaperlessBilling`  | Object       | Categorical      |
| `PaymentMethod`     | Object       | Categorical      |
| `MonthlyCharges`    | Float64      | Numerical        |
| `TotalCharges`      | Object       | Categorical (should be numerical, but likely has non-numeric values) |
| `Churn`             | Object       | Categorical      |

### Notes:
- **Numerical features**: These are the ones that contain numeric data types (`int64`, `float64`).
- **Categorical features**: These are `object` types that generally represent categories.
- The `TotalCharges` column is an object, but it might need conversion to numeric (after cleaning) since it's likely a numeric field stored as a string due to potential non-numeric values.
in percentage how % mnay categoricla vs nurmerical here