ITC Analytics Accelerator
Workshop
- Forecast vs Prediction
- OKR
Model Performance Testing
- Confusion Matrix
- To Identify false positives & true negatives
- Precision = True positives /(True positives + False Positives)
- Recall = True positives / (True positives + False Negatives)
Code
General
* import pandas as pd
* var = pd.read_csv('used_cars_maruti.csv')
* var.describe() | statistics of the data
* var.info() | summary
* var.shape | Rows and columns
* var[0:5] | range of rows to be shown. Minus 5 is also possible
* var['Column Title'][0:5] | First 5 rows are shown
* var[['Column Title','Column Title']][0:5]
* var.sample(3) | Random sampling of any 3
* var.describe(include = 'all')
* newvar = var [var.Column Title < 15] | Filtering
* var.sort_values('Price', ascending = False) [0:5]
* vars.head() | vars.tail()
* corr_mat = cars_df[['Price', 'Age', 'Power','Mileage']].corr() | Correlation
** corr_mat
Plotting =
* import matplotlib.pyplot as plt
* import seaborn as sn
# jointplot
sn.jointplot(x='Price',y='Age',
data=cars_df,kind='hex');
plt.show()
# Heatmap
sn.clustermap(corr_mat, cmap="GnBu");
plt.show()
# Heatmap with colour
sn.clustermap(corr_mat,cmap='coolwarm',
standard_scale=1);
plt.show()
OVERVIEW
5i: Ideation: defining Intelligence: process of prediciton Inception: model building Intervention: Developing a segment Independance: Live DATA ENGINEERING collection Sructuring Cleaning ALGORITHUMS Classification & Regression Decision Tree Tree based Algorithums (RF model Ensemble models MODEL PERFORMANCE Model selection AI & ML ML supervised Unsupervised DEEP LEARNING Reinforment learning CNN IMPLEMENTATION of ADVANCED ANALTICS Tracking CHANGE MANAGEMENT Piller & Practics
Advanced Analytics
Value of AA
- Evolution: Excel > Storage > Tableu > Alerts > predicting the future > ML >
- Applications:
- Descriptive (historical. advanced statistics) >
- Predictive (Future. Uses ML. detection of fraud) >
- Prescriptive (influence the future. Data driven decision making); Optimization;
Five concepts
Statistical Learning
- Frame of understanding the data based on statistics
- Eg: L.Regression: Used in predictive analytics
- Linear model: regression or classification
Inference vs prediction
- Inference : process of evaluating the relationship of predictor and the response
- Prediction: process of using a model that is yet to happen
Flexibility vs Interpretability of models
- Flexibility: capture a wide range of phenomena (Data fit)
- Interpretability : Design a Pattern to facilitate the decision
Regression vs classification
- Regression : Continuous variable.
- classification: discrete variable
Supervised vs unsupervised learning
- Supervised " Labelled data sets, Training , CNN , Decision tree
- unsupervised : Classification
- Anomaly detection
- Find hidden structure
- Eg: Customer segmentation; Purchase patterns, simplify data, monitoring