Download as pdf or txt
Download as pdf or txt
You are on page 1of 306

#1 Introduction to Probability and Statistics

Probability and Statistics Page 1


Probability and Statistics Page 2
#2 Population and Sample

Probability and Statistics Page 3


#3 Gaussian Normal Distribution and its PDF(Probability Density
Function)

Probability and Statistics Page 4


Probability and Statistics Page 5
Probability and Statistics Page 6
#4 CDF(Cumulative Distribution function) of Gaussian Normal
distribution

Probability and Statistics Page 7


Probability and Statistics Page 8
#5 Symmetric distribution, Skewness and Kurtosis

Probability and Statistics Page 9


#6 Standard normal variate (Z) and Standardization

Probability and Statistics Page 10


Probability and Statistics Page 11
#7 Kernel density estimation

Probability and Statistics Page 12


#8 Sampling distribution & Central Limit Theorem

Probability and Statistics Page 13


Probability and Statistics Page 14
Probability and Statistics Page 15
#9 (Q-Q plot) How to test if a random variable is normally distributed or
not

Probability and Statistics Page 16


Probability and Statistics Page 17
#10 How distributions are used ?

Probability and Statistics Page 18


Probability and Statistics Page 19
#11 Chebyshev’s Inequality

Probability and Statistics Page 20


Probability and Statistics Page 21
Probability and Statistics Page 22
#12 Discrete and Continuous Uniform distributions

Probability and Statistics Page 23


Probability and Statistics Page 24
#13 Bernoulli and Binomial Distribution

Probability and Statistics Page 25


Probability and Statistics Page 26
#14 Log Normal Distribution

Probability and Statistics Page 27


Probability and Statistics Page 28
Probability and Statistics Page 29
#15 Power Law Distribution

Probability and Statistics Page 30


Probability and Statistics Page 31
#16 Box Cox Transform

Probability and Statistics Page 32


Probability and Statistics Page 33
#17 Applications of non-gaussian distributions

Probability and Statistics Page 34


Probability and Statistics Page 35
Probability and Statistics Page 36
#18 Co-Variance

Probability and Statistics Page 37


Probability and Statistics Page 38
#19 Pearson Correlation Coefficient

Probability and Statistics Page 39


#20 Spearman Rank Correlation Coefficient

Probability and Statistics Page 40


Probability and Statistics Page 41
#21 Correlation vs Causation

Probability and Statistics Page 42


#22 How to use Correlations

Probability and Statistics Page 43


Probability and Statistics Page 44
#23 Confidence Interval (C.I) Introduction

Probability and Statistics Page 45


Probability and Statistics Page 46
#24 Computing Confidence Interval given Normal Distribution

Probability and Statistics Page 47


Probability and Statistics Page 48
#25 C.I for mean for any Random Variable

Probability and Statistics Page 49


Probability and Statistics Page 50
Probability and Statistics Page 51
#26 Confidence Interval using Bootstrapping

Probability and Statistics Page 52


Probability and Statistics Page 53
#27 Hypothesis testing methodology, Null-hypothesis, p-value

Probability and Statistics Page 54


Probability and Statistics Page 55
#28 Hypothesis Testing Intuition with coin toss example

Probability and Statistics Page 56


Probability and Statistics Page 57
Probability and Statistics Page 58
#29 Resampling and permutation test

Probability and Statistics Page 59


Probability and Statistics Page 60
#30 Kolmogorov-Smirnov(K-S) Test for similarity of two Distributions

Probability and Statistics Page 61


Probability and Statistics Page 62
Probability and Statistics Page 63
#31 Hypothesis testing another example

Probability and Statistics Page 64


Probability and Statistics Page 65
Probability and Statistics Page 66
#32 Resampling and Permutation test another example

Probability and Statistics Page 67


Probability and Statistics Page 68
Probability and Statistics Page 69
#33 How to use hypothesis testing ?

Probability and Statistics Page 70


Probability and Statistics Page 71
Probability and Statistics Page 72
#34 Proportional Sampling

Probability and Statistics Page 73


Probability and Statistics Page 74
#1 Geometric intuition of Logistic Regression
12 November 2020 04:31 PM

Logistic Regression Page 75


Logistic Regression Page 76
Logistic Regression Page 77
#2 Squashing and Sigmoid function
12 November 2020 08:02 PM

Logistic Regression Page 78


Logistic Regression Page 79
Logistic Regression Page 80
#3 Mathematical formulation of Objective function

Logistic Regression Page 81


Logistic Regression Page 82
#4 Weight vector

Logistic Regression Page 83


Logistic Regression Page 84
#5 L2 Regularization Overfitting and Underfitting

Logistic Regression Page 85


Logistic Regression Page 86
Logistic Regression Page 87
#6 L1 regularization and sparsity

Logistic Regression Page 88


Logistic Regression Page 89
Logistic Regression Page 90
#7 Probabilistic Interpretation Gaussian Naive Bayes

Logistic Regression Page 91


Logistic Regression Page 92
#8 Loss Minimization Interpretation

Logistic Regression Page 93


Logistic Regression Page 94
#9 Hyperparameters and Random Search

Logistic Regression Page 95


Logistic Regression Page 96
Logistic Regression Page 97
#10 Column Standardization

Logistic Regression Page 98


#11 Feature Importance and Model Interpretability

Logistic Regression Page 99


Logistic Regression Page 100
#12 Model Interpretability and Collinearity of features

Logistic Regression Page 101


Logistic Regression Page 102
Logistic Regression Page 103
#13 Test Run time Space and Time complexity

Logistic Regression Page 104


Logistic Regression Page 105
#14 Real world cases

Logistic Regression Page 106


Logistic Regression Page 107
#15 Non-linearly separable data & feature engineering

Logistic Regression Page 108


Logistic Regression Page 109
Logistic Regression Page 110
Logistic Regression Page 111
#16 Extensions to Generalized linear models

Logistic Regression Page 112


#1 Geometric Intuition of Linear Regression

Linear Regression Page 113


Linear Regression Page 114
#2 Mathematical formulation

Linear Regression Page 115


Linear Regression Page 116
#3 Real world Cases

Linear Regression Page 117


Linear Regression Page 118
#1 Differentiation

Solving Optimization Problems Page 119


Solving Optimization Problems Page 120
Solving Optimization Problems Page 121
#2 Maxima and Minima

Solving Optimization Problems Page 122


Solving Optimization Problems Page 123
#3 Vector calculus: Gradient

Solving Optimization Problems Page 124


Solving Optimization Problems Page 125
#4 Gradient Descent Geometric Intuition

Solving Optimization Problems Page 126


Solving Optimization Problems Page 127
Solving Optimization Problems Page 128
#5 Learning Rate

Solving Optimization Problems Page 129


#6 Gradient descent for Linear Regression

Solving Optimization Problems Page 130


Solving Optimization Problems Page 131
#7 Stochastic Gradient Descent (SGD) Algorithm

Solving Optimization Problems Page 132


Solving Optimization Problems Page 133
#8 Constrained Optimization & PCA

Solving Optimization Problems Page 134


Solving Optimization Problems Page 135
#9 Logistic Regression formulation revisited

Solving Optimization Problems Page 136


#10 Why L1 regularization creates sparsity

Solving Optimization Problems Page 137


Solving Optimization Problems Page 138
#1 Geometric Intuition

Support Vector Machine- SVM Page 139


Support Vector Machine- SVM Page 140
#2 Mathematical Formulations (Hard Margin SVM)

zz

Support Vector Machine- SVM Page 141


Support Vector Machine- SVM Page 142
#3 Mathematical Formulations (Soft Margin SVM)

Support Vector Machine- SVM Page 143


Support Vector Machine- SVM Page 144
#4 Why we take values +1 & -1 for Support vector planes?

Support Vector Machine- SVM Page 145


Support Vector Machine- SVM Page 146
#5 Loss function (Hinge Loss) based interpretation

Support Vector Machine- SVM Page 147


Support Vector Machine- SVM Page 148
#6 Dual form of SVM formulation

Support Vector Machine- SVM Page 149


#7 Kernel trick

Support Vector Machine- SVM Page 150


Support Vector Machine- SVM Page 151
#8 Polynomial Kernel

Support Vector Machine- SVM Page 152


Support Vector Machine- SVM Page 153
#9 Radial Basis Function (RBF) Kernel

Support Vector Machine- SVM Page 154


Support Vector Machine- SVM Page 155
Support Vector Machine- SVM Page 156
#10 Domain specific Kernels

Support Vector Machine- SVM Page 157


#11 Train and Run time complexities

Support Vector Machine- SVM Page 158


Support Vector Machine- SVM Page 159
#12 nu-SVM control errors and Support Vectors

Support Vector Machine- SVM Page 160


#13 SVM Regression

Support Vector Machine- SVM Page 161


#14 Some real world Cases

Support Vector Machine- SVM Page 162


Support Vector Machine- SVM Page 163
#1 Conditional Probability

Naive Bayes Page 164


#2 Independent vs Mutually exclusive events

Naive Bayes Page 165


#3 Bayes Theorem with examples

Naive Bayes Page 166


#4 Naïve Bayes algorithm

Naive Bayes Page 167


#5 Toy example Train and test stages

http://shatterline.com/blog/2013/09/12/not-so-naive-classification-with-the-naive-bayes-classifier/

Naive Bayes Page 168


#6 Naïve Bayes on Text data

Naive Bayes Page 169


Naive Bayes Page 170
#7 Laplace Additive Smoothing

Naive Bayes Page 171


Naive Bayes Page 172
Naive Bayes Page 173
#8 Log-Probabilities for numerical stability

Naive Bayes Page 174


Naive Bayes Page 175
#9 Bias and Variance trade off

Naive Bayes Page 176


Naive Bayes Page 177
Naive Bayes Page 178
#10 Feature importance and interpretability

Naive Bayes Page 179


Naive Bayes Page 180
#11 Imbalanced Data

Naive Bayes Page 181


Naive Bayes Page 182
Naive Bayes Page 183
#12 Outliers

Naive Bayes Page 184


#13 Missing values

Naive Bayes Page 185


#14 Handling Numerical features (Gaussian NB)

Naive Bayes Page 186


Naive Bayes Page 187
#15 Multiclass classification

Naive Bayes Page 188


#16 Similarity or Distance matrix

Naive Bayes Page 189


#17 Large dimensionality

Naive Bayes Page 190


#18 Best and worst cases

Naive Bayes Page 191


Naive Bayes Page 192
#1 How “Classification” works

K-Nearest Neighbours Page 193


K-Nearest Neighbours Page 194
#2 Data matrix notation

K-Nearest Neighbours Page 195


#3 Classification vs Regression (examples)

K-Nearest Neighbours Page 196


K-Nearest Neighbours Page 197
#4 K-Nearest Neighbours Geometric intuition with a toy example

K-Nearest Neighbours Page 198


K-Nearest Neighbours Page 199
#5 Failure cases of KNN

K-Nearest Neighbours Page 200


#6 Distance measures Euclidean(L2) , Manhaltan(L1), Minkowski,
Hamming

K-Nearest Neighbours Page 201


K-Nearest Neighbours Page 202
K-Nearest Neighbours Page 203
#7 Cosine Distance & Cosine Similarity

K-Nearest Neighbours Page 204


K-Nearest Neighbours Page 205
K-Nearest Neighbours Page 206
#8 How to measure the effectiveness of k-NN

K-Nearest Neighbours Page 207


K-Nearest Neighbours Page 208
K-Nearest Neighbours Page 209
#9 Test Evaluation time and space complexity

K-Nearest Neighbours Page 210


K-Nearest Neighbours Page 211
#10 KNN Limitations

K-Nearest Neighbours Page 212


K-Nearest Neighbours Page 213
#11 Decision surface for K-NN as K changes

K-Nearest Neighbours Page 214


K-Nearest Neighbours Page 215
#12 Overfitting and Underfitting

K-Nearest Neighbours Page 216


#13 Why need for Cross validation?

K-Nearest Neighbours Page 217


K-Nearest Neighbours Page 218
K-Nearest Neighbours Page 219
K-Nearest Neighbours Page 220
#14 K-fold cross validation

K-Nearest Neighbours Page 221


K-Nearest Neighbours Page 222
#15 Visualizing train, validation and test datasets

K-Nearest Neighbours Page 223


K-Nearest Neighbours Page 224
#16 How to determine overfitting and underfitting?

K-Nearest Neighbours Page 225


K-Nearest Neighbours Page 226
K-Nearest Neighbours Page 227
#17 Time based splitting

K-Nearest Neighbours Page 228


K-Nearest Neighbours Page 229
K-Nearest Neighbours Page 230
#18 k-NN for regression

K-Nearest Neighbours Page 231


#19 Weighted k-NN

K-Nearest Neighbours Page 232


#20 Binary Search Tree

K-Nearest Neighbours Page 233


K-Nearest Neighbours Page 234
#21 How to build a kd-tree

K-Nearest Neighbours Page 235


#22 Find nearest neighbors using kd-tree

K-Nearest Neighbours Page 236


#23 Limitations of KD tree

K-Nearest Neighbours Page 237


K-Nearest Neighbours Page 238
#24 Hashing vs LSH

K-Nearest Neighbours Page 239


#25 LSH for cosine similarity

K-Nearest Neighbours Page 240


K-Nearest Neighbours Page 241
K-Nearest Neighbours Page 242
K-Nearest Neighbours Page 243
K-Nearest Neighbours Page 244
K-Nearest Neighbours Page 245
#26 LSH for Euclidean Distance

K-Nearest Neighbours Page 246


K-Nearest Neighbours Page 247
#27 Probabilistic class label

K-Nearest Neighbours Page 248


K-Nearest Neighbours Page 249
#1 Geometric Intuition of decision tree Axis parallel hyperplanes

Decision Tree Page 250


Decision Tree Page 251
#2 Sample Example

Decision Tree Page 252


#3 Entropy

Decision Tree Page 253


Decision Tree Page 254
Decision Tree Page 255
#4 Information Gain

Decision Tree Page 256


#5 Gini Impurity

Decision Tree Page 257


Decision Tree Page 258
#6 Decision Tree Constructing

Decision Tree Page 259


Decision Tree Page 260
Decision Tree Page 261
#7 Splitting Numerical features

[[

Decision Tree Page 262


[[]

Decision Tree Page 263


#8 Do we need Feature Standardization ?

Decision Tree Page 264


Decision Tree Page 265
#9 Categorical features with many possible values

Decision Tree Page 266


Decision Tree Page 267
#10 Overfitting and Underfitting

Decision Tree Page 268


Decision Tree Page 269
#11 Train and Run time complexity

Decision Tree Page 270


Decision Tree Page 271
#12 Regression using Decision Trees

Decision Tree Page 272


Decision Tree Page 273
#13 Cases

Decision Tree Page 274


Decision Tree Page 275
Decision Tree Page 276
Decision Tree Page 277
#1 What are ensembles ?

Ensemble Models Page 278


Ensemble Models Page 279
#2 Bootstrapped Aggregation (Bagging) Intuition

Ensemble Models Page 280


Ensemble Models Page 281
#3 Random Forest and its construction

Ensemble Models Page 282


Ensemble Models Page 283
#4 Bias-Variance trade-off

Ensemble Models Page 284


Ensemble Models Page 285
#5 Train and run time complexity

Ensemble Models Page 286


#6 Extremely randomized trees

Ensemble Models Page 287


#7 Random Tree Cases

Ensemble Models Page 288


Ensemble Models Page 289
#8 Boosting Intuition

Ensemble Models Page 290


Ensemble Models Page 291
Ensemble Models Page 292
#9 Residuals, Loss functions and gradients

Ensemble Models Page 293


Ensemble Models Page 294
Ensemble Models Page 295
#10 Gradient Boosting

Ensemble Models Page 296


#11 Regularization by Shrinkage

Ensemble Models Page 297


Ensemble Models Page 298
#12 Train and Run time complexity Gradient Boosting Decision Tree

Ensemble Models Page 299


Ensemble Models Page 300
#13 AdaBoost geometric intuition

Ensemble Models Page 301


Ensemble Models Page 302
#14 Stacking models

Ensemble Models Page 303


Ensemble Models Page 304
#15 Cascading Classifiers

Ensemble Models Page 305


Ensemble Models Page 306

You might also like