16 |
17 |
18 |
--------------------------------------------------------------------------------
/code/ch09/movieclassifier_with_update/update.py:
--------------------------------------------------------------------------------
1 | import pickle
2 | import sqlite3
3 | import numpy as np
4 | import os
5 |
6 | # import HashingVectorizer from local dir
7 | from vectorizer import vect
8 |
9 | def update_model(db_path, model, batch_size=10000):
10 |
11 | conn = sqlite3.connect(db_path)
12 | c = conn.cursor()
13 | c.execute('SELECT * from review_db')
14 |
15 | results = c.fetchmany(batch_size)
16 | while results:
17 | data = np.array(results)
18 | X = data[:, 0]
19 | y = data[:, 1].astype(int)
20 |
21 | classes = np.array([0, 1])
22 | X_train = vect.transform(X)
23 | model.partial_fit(X_train, y, classes=classes)
24 | results = c.fetchmany(batch_size)
25 |
26 | conn.close()
27 | return model
28 |
29 | cur_dir = os.path.dirname(__file__)
30 |
31 | clf = pickle.load(open(os.path.join(cur_dir,
32 | 'pkl_objects',
33 | 'classifier.pkl'), 'rb'))
34 | db = os.path.join(cur_dir, 'reviews.sqlite')
35 |
36 | clf = update_model(db_path=db, model=clf, batch_size=10000)
37 |
38 | # Uncomment the following lines if you are sure that
39 | # you want to update your classifier.pkl file
40 | # permanently.
41 |
42 | # pickle.dump(clf, open(os.path.join(cur_dir,
43 | # 'pkl_objects', 'classifier.pkl'), 'wb')
44 | # , protocol=4)
45 |
--------------------------------------------------------------------------------
/code/ch09/movieclassifier_with_update/vectorizer.py:
--------------------------------------------------------------------------------
1 | from sklearn.feature_extraction.text import HashingVectorizer
2 | import re
3 | import os
4 | import pickle
5 |
6 | cur_dir = os.path.dirname(__file__)
7 | stop = pickle.load(open(
8 | os.path.join(cur_dir,
9 | 'pkl_objects',
10 | 'stopwords.pkl'), 'rb'))
11 |
12 | def tokenizer(text):
13 | text = re.sub('<[^>]*>', '', text)
14 | emoticons = re.findall('(?::|;|=)(?:-)?(?:\)|\(|D|P)',
15 | text.lower())
16 | text = re.sub('[\W]+', ' ', text.lower()) \
17 | + ' '.join(emoticons).replace('-', '')
18 | tokenized = [w for w in text.split() if w not in stop]
19 | return tokenized
20 |
21 | vect = HashingVectorizer(decode_error='ignore',
22 | n_features=2**21,
23 | preprocessor=None,
24 | tokenizer=tokenizer)
25 |
--------------------------------------------------------------------------------
/code/ch09/pickle-test-scripts/README.md:
--------------------------------------------------------------------------------
1 | **Note**
2 |
3 | The pickling-section may be a bit tricky so that I included simpler test scripts in this directory (pickle-test-scripts/) to check if your environment is set up correctly. Basically, it is just a trimmed-down version of the relevant sections from Ch08, including a very small movie_review_data subset.
4 |
5 | Executing
6 |
7 | python pickle-dump-test.py
8 |
9 | will train a small classification model from the `movie_data_small.csv` and create the 2 pickle files
10 |
11 | stopwords.pkl
12 | classifier.pkl
13 |
14 | Next, if you execute
15 |
16 | python pickle-load-test.py
17 |
18 | You should see the following 2 lines as output:
19 |
20 | Prediction: positive
21 | Probability: 85.71%
--------------------------------------------------------------------------------
/code/ch09/pickle-test-scripts/pickle-load-test.py:
--------------------------------------------------------------------------------
1 | import pickle
2 | import re
3 | import os
4 | from vectorizer import vect
5 | import numpy as np
6 |
7 | clf = pickle.load(open('classifier.pkl', 'rb'))
8 |
9 |
10 | label = {0: 'negative', 1: 'positive'}
11 | example = ['I love this movie']
12 |
13 | X = vect.transform(example)
14 |
15 | print('Prediction: %s\nProbability: %.2f%%' %
16 | (label[clf.predict(X)[0]],
17 | np.max(clf.predict_proba(X)) * 100))
18 |
--------------------------------------------------------------------------------
/code/ch09/pickle-test-scripts/vectorizer.py:
--------------------------------------------------------------------------------
1 | from sklearn.feature_extraction.text import HashingVectorizer
2 | import re
3 | import os
4 | import pickle
5 |
6 |
7 | stop = pickle.load(open('stopwords.pkl', 'rb'))
8 |
9 |
10 | def tokenizer(text):
11 | text = re.sub('<[^>]*>', '', text)
12 | emoticons = re.findall('(?::|;|=)(?:-)?(?:\)|\(|D|P)',
13 | text.lower())
14 | text = re.sub('[\W]+', ' ', text.lower()) + \
15 | ' '.join(emoticons).replace('-', '')
16 | tokenized = [w for w in text.split() if w not in stop]
17 | return tokenized
18 |
19 | vect = HashingVectorizer(decode_error='ignore',
20 | n_features=2**21,
21 | preprocessor=None,
22 | tokenizer=tokenizer)
23 |
--------------------------------------------------------------------------------
/code/ch10/README.md:
--------------------------------------------------------------------------------
1 | Sebastian Raschka, 2015
2 |
3 | Python Machine Learning - Code Examples
4 |
5 | ## Chapter 10 - Predicting Continuous Target Variables with Regression Analysis
6 |
7 | - Introducing a simple linear regression model
8 | - Exploring the Housing Dataset
9 | - Visualizing the important characteristics of a dataset
10 | - Implementing an ordinary least squares linear regression model
11 | - Solving regression for regression parameters with gradient descent
12 | - Estimating the coefficient of a regression model via scikit-learn
13 | - Fitting a robust regression model using RANSAC
14 | - Evaluating the performance of linear regression models
15 | - Using regularized methods for regression
16 | - Turning a linear regression model into a curve – polynomial regression
17 | - Modeling nonlinear relationships in the Housing Dataset
18 | - Dealing with nonlinear relationships using random forests
19 | - Decision tree regression
20 | - Random forest regression
21 | - Summary
--------------------------------------------------------------------------------
/code/ch10/images/10_01.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_01.png
--------------------------------------------------------------------------------
/code/ch10/images/10_02.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_02.png
--------------------------------------------------------------------------------
/code/ch10/images/10_03.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_03.png
--------------------------------------------------------------------------------
/code/ch10/images/10_04.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_04.png
--------------------------------------------------------------------------------
/code/ch10/images/10_05.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_05.png
--------------------------------------------------------------------------------
/code/ch10/images/10_06.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_06.png
--------------------------------------------------------------------------------
/code/ch10/images/10_07.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_07.png
--------------------------------------------------------------------------------
/code/ch10/images/10_08.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_08.png
--------------------------------------------------------------------------------
/code/ch10/images/10_09.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_09.png
--------------------------------------------------------------------------------
/code/ch10/images/10_10.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_10.png
--------------------------------------------------------------------------------
/code/ch10/images/10_11.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_11.png
--------------------------------------------------------------------------------
/code/ch10/images/10_12.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_12.png
--------------------------------------------------------------------------------
/code/ch10/images/10_13.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_13.png
--------------------------------------------------------------------------------
/code/ch10/images/10_14.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch10/images/10_14.png
--------------------------------------------------------------------------------
/code/ch11/README.md:
--------------------------------------------------------------------------------
1 | Sebastian Raschka, 2015
2 |
3 | Python Machine Learning - Code Examples
4 |
5 | ## Chapter 11 - Working with Unlabeled Data – Clustering Analysis
6 |
7 | - Grouping objects by similarity using k-means
8 | - K-means++
9 | - Hard versus soft clustering
10 | - Using the elbow method to find the optimal number of clusters
11 | - Quantifying the quality of clustering via silhouette plots
12 | - Organizing clusters as a hierarchical tree
13 | - Performing hierarchical clustering on a distance matrix
14 | - Attaching dendrograms to a heat map
15 | - Applying agglomerative clustering via scikit-learn
16 | - Locating regions of high density via DBSCAN
17 | - Summary
--------------------------------------------------------------------------------
/code/ch11/images/11_01.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_01.png
--------------------------------------------------------------------------------
/code/ch11/images/11_02.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_02.png
--------------------------------------------------------------------------------
/code/ch11/images/11_03.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_03.png
--------------------------------------------------------------------------------
/code/ch11/images/11_04.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_04.png
--------------------------------------------------------------------------------
/code/ch11/images/11_05.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_05.png
--------------------------------------------------------------------------------
/code/ch11/images/11_06.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_06.png
--------------------------------------------------------------------------------
/code/ch11/images/11_07.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_07.png
--------------------------------------------------------------------------------
/code/ch11/images/11_08.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_08.png
--------------------------------------------------------------------------------
/code/ch11/images/11_09.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_09.png
--------------------------------------------------------------------------------
/code/ch11/images/11_10.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_10.png
--------------------------------------------------------------------------------
/code/ch11/images/11_11.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_11.png
--------------------------------------------------------------------------------
/code/ch11/images/11_12.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_12.png
--------------------------------------------------------------------------------
/code/ch11/images/11_13.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_13.png
--------------------------------------------------------------------------------
/code/ch11/images/11_14.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_14.png
--------------------------------------------------------------------------------
/code/ch11/images/11_15.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_15.png
--------------------------------------------------------------------------------
/code/ch11/images/11_16.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch11/images/11_16.png
--------------------------------------------------------------------------------
/code/ch12/README.md:
--------------------------------------------------------------------------------
1 | Sebastian Raschka, 2015
2 |
3 | Python Machine Learning - Code Examples
4 |
5 | ## Chapter 12 - Training Artificial Neural Networks for Image
6 |
7 | - Modeling complex functions with artificial neural networks
8 | - Single-layer neural network recap
9 | - Introducing the multi-layer neural network architecture
10 | - Activating a neural network via forward propagation
11 | - Classifying handwritten digits
12 | - Obtaining the MNIST dataset
13 | - Implementing a multi-layer perceptron
14 | - Training an artificial neural network
15 | - Computing the logistic cost function
16 | - Training neural networks via backpropagation
17 | - Developing your intuition for backpropagation
18 | - Debugging neural networks with gradient checking
19 | - Convergence in neural networks
20 | - Other neural network architectures
21 | - Convolutional Neural Networks
22 | - Recurrent Neural Networks
23 | - A few last words about neural network implementation
24 | - Summary
--------------------------------------------------------------------------------
/code/ch12/images/12_01.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_01.png
--------------------------------------------------------------------------------
/code/ch12/images/12_02.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_02.png
--------------------------------------------------------------------------------
/code/ch12/images/12_03.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_03.png
--------------------------------------------------------------------------------
/code/ch12/images/12_04.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_04.png
--------------------------------------------------------------------------------
/code/ch12/images/12_05.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_05.png
--------------------------------------------------------------------------------
/code/ch12/images/12_06.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_06.png
--------------------------------------------------------------------------------
/code/ch12/images/12_07.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_07.png
--------------------------------------------------------------------------------
/code/ch12/images/12_08.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_08.png
--------------------------------------------------------------------------------
/code/ch12/images/12_09.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_09.png
--------------------------------------------------------------------------------
/code/ch12/images/12_10.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_10.png
--------------------------------------------------------------------------------
/code/ch12/images/12_11.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_11.png
--------------------------------------------------------------------------------
/code/ch12/images/12_12.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_12.png
--------------------------------------------------------------------------------
/code/ch12/images/12_13.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_13.png
--------------------------------------------------------------------------------
/code/ch12/images/12_14.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_14.png
--------------------------------------------------------------------------------
/code/ch12/images/12_15.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_15.png
--------------------------------------------------------------------------------
/code/ch12/images/12_16.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_16.png
--------------------------------------------------------------------------------
/code/ch12/images/12_17.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch12/images/12_17.png
--------------------------------------------------------------------------------
/code/ch13/README.md:
--------------------------------------------------------------------------------
1 | Sebastian Raschka, 2015
2 |
3 | Python Machine Learning - Code Examples
4 |
5 | ## Chapter 13 - Parallelizing Neural Network Training with Theano
6 |
7 | - Building, compiling, and running expressions with Theano
8 | - What is Theano?
9 | - First steps with Theano
10 | - Configuring Theano
11 | - Working with array structures
12 | - Wrapping things up – a linear regression example
13 | - Choosing activation functions for feedforward neural networks
14 | - Logistic function recap
15 | - Estimating probabilities in multi-class classification via the softmax function
16 | - Broadening the output spectrum by using a hyperbolic tangent
17 | - Training neural networks efficiently using Keras
18 | - Summary
--------------------------------------------------------------------------------
/code/ch13/images/13_01.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch13/images/13_01.png
--------------------------------------------------------------------------------
/code/ch13/images/13_02.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch13/images/13_02.png
--------------------------------------------------------------------------------
/code/ch13/images/13_03.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch13/images/13_03.png
--------------------------------------------------------------------------------
/code/ch13/images/13_04.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch13/images/13_04.png
--------------------------------------------------------------------------------
/code/ch13/images/13_05.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch13/images/13_05.png
--------------------------------------------------------------------------------
/code/ch13/images/bonus_softmax_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/ch13/images/bonus_softmax_1.png
--------------------------------------------------------------------------------
/code/datasets/iris/README.md:
--------------------------------------------------------------------------------
1 | Sebastian Raschka, 2015
2 |
3 | # Python Machine Learning - Supplementary Datasets
4 |
5 | ## Iris Flower Dataset
6 |
7 | - Used in chapters 1, 2, and 3
8 |
9 | The Iris dataset for classification.
10 |
11 | **Features**
12 |
13 | 1. Sepal length
14 | 2. Sepal width
15 | 3. Petal length
16 | 4. Petal width
17 |
18 | - Number of samples: 150
19 |
20 | - Target variable (discrete): {50x Setosa, 50x Versicolor, 50x Virginica}
21 |
22 | ### References
23 |
24 | - Source: [https://archive.ics.uci.edu/ml/datasets/Iris](https://archive.ics.uci.edu/ml/datasets/Iris)
25 | - Bache, K. & Lichman, M. (2013). UCI Machine Learning Repository. Irvine, CA: University of California, School of Information and Computer Science.
26 |
--------------------------------------------------------------------------------
/code/datasets/mnist/t10k-images-idx3-ubyte.gz:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/datasets/mnist/t10k-images-idx3-ubyte.gz
--------------------------------------------------------------------------------
/code/datasets/mnist/t10k-labels-idx1-ubyte.gz:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/datasets/mnist/t10k-labels-idx1-ubyte.gz
--------------------------------------------------------------------------------
/code/datasets/mnist/train-images-idx3-ubyte.gz:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/datasets/mnist/train-images-idx3-ubyte.gz
--------------------------------------------------------------------------------
/code/datasets/mnist/train-labels-idx1-ubyte.gz:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/datasets/mnist/train-labels-idx1-ubyte.gz
--------------------------------------------------------------------------------
/code/datasets/movie/README.md:
--------------------------------------------------------------------------------
1 | Sebastian Raschka, 2015
2 |
3 | # Python Machine Learning - Supplementary Datasets
4 |
5 | ## The Large Movie Review Dataset
6 |
7 | - Used in chapters 8 and 9
8 |
9 | The movie dataset converted into a 2-column CSV format: The first column (`review`) contains the text, and the second column (`sentiment`) denotes the polarity, where 0=negative and 1=positive. The first 25,000 are the training samples and the remaining 25,000 rows are the test samples from the "Large Movie Review Dataset v1.0," respectively.
10 |
11 | - Source: [http://ai.stanford.edu/~amaas/data/sentiment/](http://ai.stanford.edu/~amaas/data/sentiment/)
12 |
--------------------------------------------------------------------------------
/code/datasets/movie/movie_data.csv.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/code/datasets/movie/movie_data.csv.zip
--------------------------------------------------------------------------------
/code/datasets/wdbc/README.md:
--------------------------------------------------------------------------------
1 | Sebastian Raschka, 2015
2 |
3 | # Python Machine Learning - Supplementary Datasets
4 |
5 | ## Breast Cancer Wisconsin (Diagnostic) Data Set
6 |
7 | - Used in chapter 6
8 | - Source: https://archive.ics.uci.edu/ml/datasets/Breast+Cancer+Wisconsin+(Diagnostic)
9 |
--------------------------------------------------------------------------------
/code/optional-py-scripts/ch09.py:
--------------------------------------------------------------------------------
1 | # Sebastian Raschka, 2015 (http://sebastianraschka.com)
2 | # Python Machine Learning - Code Examples
3 | #
4 | # Chapter 9 - Embedding a Machine Learning Model into a Web Application
5 | #
6 | # S. Raschka. Python Machine Learning. Packt Publishing Ltd., 2015.
7 | # GitHub Repo: https://github.com/rasbt/python-machine-learning-book
8 | #
9 | # License: MIT
10 | # https://github.com/rasbt/python-machine-learning-book/blob/master/LICENSE.txt
11 |
12 |
13 | s = """
14 |
15 | Due to the complexity of this chapter, and the many files involved,
16 | please refer to the IPython Notebook at
17 | https://github.com/rasbt/python-machine-learning-book/blob/master/code/ch09/ch09.ipynb
18 |
19 | The web application files can be obtained from
20 | https://github.com/rasbt/python-machine-learning-book/tree/master/code/ch09
21 |
22 | """
23 | print(s)
24 |
--------------------------------------------------------------------------------
/docs/2016-03-03-unicef.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/2016-03-03-unicef.pdf
--------------------------------------------------------------------------------
/docs/2016-04-07-unicef.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/2016-04-07-unicef.pdf
--------------------------------------------------------------------------------
/docs/2016-11-10-commoncause.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/2016-11-10-commoncause.png
--------------------------------------------------------------------------------
/docs/equations/pymle-equations.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/equations/pymle-equations.pdf
--------------------------------------------------------------------------------
/docs/foreword_ro.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/foreword_ro.pdf
--------------------------------------------------------------------------------
/docs/images/armand_g_tweet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/images/armand_g_tweet.png
--------------------------------------------------------------------------------
/docs/images/boris_tweet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/images/boris_tweet.png
--------------------------------------------------------------------------------
/docs/images/claus_tweet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/images/claus_tweet.png
--------------------------------------------------------------------------------
/docs/images/dataelixir.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/images/dataelixir.png
--------------------------------------------------------------------------------
/docs/images/errata/errata_2015-10-20.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/images/errata/errata_2015-10-20.png
--------------------------------------------------------------------------------
/docs/images/errata/errata_2016-04-22.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/images/errata/errata_2016-04-22.jpg
--------------------------------------------------------------------------------
/docs/images/jason_tweet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/images/jason_tweet.png
--------------------------------------------------------------------------------
/docs/images/jonathon_m_tweet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/images/jonathon_m_tweet.png
--------------------------------------------------------------------------------
/docs/images/josiah_tweet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/images/josiah_tweet.png
--------------------------------------------------------------------------------
/docs/images/matteo_tweet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/images/matteo_tweet.png
--------------------------------------------------------------------------------
/docs/images/matthew_m_tweet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/images/matthew_m_tweet.png
--------------------------------------------------------------------------------
/docs/images/penghui_tweet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/images/penghui_tweet.png
--------------------------------------------------------------------------------
/docs/images/yong_cho_tweet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/images/yong_cho_tweet.png
--------------------------------------------------------------------------------
/docs/preface_sr.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/preface_sr.pdf
--------------------------------------------------------------------------------
/docs/running_jupyter_nb.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/docs/running_jupyter_nb.pdf
--------------------------------------------------------------------------------
/faq/ai-and-ml/ai-and-ml-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ai-and-ml/ai-and-ml-1.png
--------------------------------------------------------------------------------
/faq/avoid-overfitting.md:
--------------------------------------------------------------------------------
1 | # How can I avoid overfitting?
2 |
3 | In short, the general strategies are to
4 |
5 | 1. collect more data
6 | 2. use ensembling methods that "average" models
7 | 3. choose simpler models / penalize complexity
8 |
9 | For the first point, it may help to plot learning curves, plotting the training vs. the validation or cross-validation performance. If you see a trend that more data helps with closing the cap between the two, and if you could afford collecting more data, then this would probably the best choice.
10 |
11 | In my experience, ensembling is probably the most convenient way to build robust predictive models on somewhat small-sized datasets. As in real life, consulting a bunch of "experts" is usually not a bad idea before making a decision ;).
12 |
13 | Regarding the third point, I usually start a predictive modeling task with the simplest model as a benchmark: usually logistic regression. Overfitting can be a real problem if our model has too much capacity — too many model parameters to fit, and too many hyperparameters to tune. If the dataset is small, a simple model is always a good option to prevent overfitting, and it is also a good benchmark for comparison to more "complex" alternatives.
14 |
--------------------------------------------------------------------------------
/faq/bagging-boosting-rf/bagging-regions.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/bagging-boosting-rf/bagging-regions.png
--------------------------------------------------------------------------------
/faq/bagging-boosting-rf/bagging.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/bagging-boosting-rf/bagging.png
--------------------------------------------------------------------------------
/faq/bagging-boosting-rf/boosting-regions.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/bagging-boosting-rf/boosting-regions.png
--------------------------------------------------------------------------------
/faq/bagging-boosting-rf/boosting.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/bagging-boosting-rf/boosting.png
--------------------------------------------------------------------------------
/faq/choosing-technique/scikit-cheatsheet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/choosing-technique/scikit-cheatsheet.png
--------------------------------------------------------------------------------
/faq/classifier-history/activation-functions.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/classifier-history/activation-functions.png
--------------------------------------------------------------------------------
/faq/classifier-history/adaline.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/classifier-history/adaline.png
--------------------------------------------------------------------------------
/faq/classifier-history/lda.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/classifier-history/lda.png
--------------------------------------------------------------------------------
/faq/classifier-history/perceptron-figure.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/classifier-history/perceptron-figure.png
--------------------------------------------------------------------------------
/faq/classifier-history/perceptron-rule.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/classifier-history/perceptron-rule.png
--------------------------------------------------------------------------------
/faq/classifier_categories/master_chart.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/classifier_categories/master_chart.jpg
--------------------------------------------------------------------------------
/faq/clf-behavior-data.md:
--------------------------------------------------------------------------------
1 | # What are the best toy datasets to help visualize and understand classifier behavior?
2 |
3 | The visualization part is a bit tricky since we as humans are limited to 1-3 D graphics. However, I'd still say Iris is one of the most useful toy datasets for looking at classifier behavior (see image below).
4 |
5 | 
6 |
7 | (I've implemented this simple function here if you are interested: [mlxtend plot_decision_regions](http://rasbt.github.io/mlxtend/user_guide/plotting/plot_decision_regions/).)
8 | Other than that, I think that synthetic datasets like "XOR," "half-moons," or concentric circles would be good candidates for evaluating classifier on non-linear problems:
9 |
10 |
11 |
12 | 
13 |
14 |
15 |
16 | 
17 |
18 |
19 |
20 | 
21 |
--------------------------------------------------------------------------------
/faq/clf-behavior-data/circles.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/clf-behavior-data/circles.png
--------------------------------------------------------------------------------
/faq/clf-behavior-data/iris.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/clf-behavior-data/iris.png
--------------------------------------------------------------------------------
/faq/clf-behavior-data/moons.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/clf-behavior-data/moons.png
--------------------------------------------------------------------------------
/faq/clf-behavior-data/xor.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/clf-behavior-data/xor.png
--------------------------------------------------------------------------------
/faq/closed-form-vs-gd/adaptive_learning.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/closed-form-vs-gd/adaptive_learning.png
--------------------------------------------------------------------------------
/faq/closed-form-vs-gd/ball.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/closed-form-vs-gd/ball.png
--------------------------------------------------------------------------------
/faq/closed-form-vs-gd/closed-form.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/closed-form-vs-gd/closed-form.png
--------------------------------------------------------------------------------
/faq/closed-form-vs-gd/decrease_const.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/closed-form-vs-gd/decrease_const.png
--------------------------------------------------------------------------------
/faq/closed-form-vs-gd/dw.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/closed-form-vs-gd/dw.png
--------------------------------------------------------------------------------
/faq/closed-form-vs-gd/iter_gd.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/closed-form-vs-gd/iter_gd.png
--------------------------------------------------------------------------------
/faq/closed-form-vs-gd/iter_sgd.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/closed-form-vs-gd/iter_sgd.png
--------------------------------------------------------------------------------
/faq/closed-form-vs-gd/j.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/closed-form-vs-gd/j.png
--------------------------------------------------------------------------------
/faq/closed-form-vs-gd/linear_model.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/closed-form-vs-gd/linear_model.png
--------------------------------------------------------------------------------
/faq/closed-form-vs-gd/simple_regression.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/closed-form-vs-gd/simple_regression.png
--------------------------------------------------------------------------------
/faq/closed-form-vs-gd/sse_mse.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/closed-form-vs-gd/sse_mse.png
--------------------------------------------------------------------------------
/faq/closed-form-vs-gd/w_upd.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/closed-form-vs-gd/w_upd.png
--------------------------------------------------------------------------------
/faq/closed-form-vs-gd/w_upd_expl.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/closed-form-vs-gd/w_upd_expl.png
--------------------------------------------------------------------------------
/faq/cost-vs-loss.md:
--------------------------------------------------------------------------------
1 | # What is the difference between a cost function and a loss function in machine learning?
2 |
3 | The terms *cost* and *loss* functions are synonymous (some people also call it error function). The more general scenario is to define an objective function first, which we want to optimize. This objective function could be to
4 |
5 | - maximize the posterior probabilities (e.g., naive Bayes)
6 | - maximize a fitness function (genetic programming)
7 | - maximize the total reward/value function (reinforcement learning)
8 | - maximize information gain/minimize child node impurities (CART decision tree classification)
9 | - minimize a mean squared error cost (or loss) function (CART, decision tree regression, linear regression, adaptive linear neurons, ...
10 | - maximize log-likelihood or minimize cross-entropy loss (or cost) function
11 | - minimize hinge loss (support vector machine)
12 | ...
13 |
--------------------------------------------------------------------------------
/faq/datamining-overview.md:
--------------------------------------------------------------------------------
1 | # What are the different fields of study in data mining?
2 |
3 |
4 | I would roughly define the different application areas as
5 |
6 | 1) Clustering (unsupervised learning)
7 | e.g., to find groups of customers based on some similarity
8 |
9 | 2) Predictive modeling (supervised learning)
10 | 2.1) Classification
11 | e.g., medical diagnosis (sick/healthy), image classification etc.
12 | 2.2) Regression
13 | e.g., stock trade change prediction
14 | 2.3) Ranking
15 | e.g., search engine results
16 |
17 | 3) Association rule mining
18 | e.g., which products do customers frequently buy together
19 |
20 | 4) Anomaly detection
21 | e.g., credit fraud detection
22 |
--------------------------------------------------------------------------------
/faq/datamining-vs-ml.md:
--------------------------------------------------------------------------------
1 | # What are differences in research nature between the two fields: Machine Learning & Data Mining?
2 |
3 | In a nutshell, Data Mining is about the discovery of patterns in datasets or "gaining knowledge and insights" from data. Machine Learning is closely related though. We can think of Machine Learning algorithms as one of the work horses of Data Mining; most Data Mining approaches are based on Machine Learning algorithms. Maybe it helps to think of Data Mining as a pipeline of steps and approaches, and the use of a Machine Learning algorithm is one part of this pipeline.
4 | Or in other words, Data Mining is not "just" Machine Learning. E.g., data visualization or summarization is also part of Data Mining. What I was trying to say is that Machine Learning is one part, one set of techniques, that is/are being used in Data Mining.
5 |
--------------------------------------------------------------------------------
/faq/dataprep-vs-dataengin.md:
--------------------------------------------------------------------------------
1 | # Should data preparation/pre-processing step be considered one part of feature engineering? Why or why not?
2 |
3 | I think there's a fuzzy boundary between these two areas of tasks. I see data preparation more as a technical/computational task. E.g., if you think about getting the data into the "right" format, choosing the appropriate data structure / database, and so forth.
4 | Then, there's data cleaning, which can also be grouped into the "preparation / pre-processing" category. Here, you may want to think about detecting duplications, how to deal with outliers, and how to deal with missing data.
5 |
6 | To me, feature engineering is a bit different. I see it more as a "data/feature creation" step rather than a data "sanitizing" step. Feature engineering may include all different sorts of feature transformations in both directions: Higher-dimensional feature spaces (e.g., polynomials), lower dimensional feature spaces (dimensionality reduction like PCA, LDA, etc., hashing, clustering), or you keep the dimensions but change the distribution of your data (e.g., log transformation, standardization, min-max scaling etc.)
7 |
--------------------------------------------------------------------------------
/faq/datascience-ml/ml-overview.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/datascience-ml/ml-overview.jpg
--------------------------------------------------------------------------------
/faq/decision-tree-binary/calc_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decision-tree-binary/calc_1.png
--------------------------------------------------------------------------------
/faq/decision-tree-binary/calc_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decision-tree-binary/calc_2.png
--------------------------------------------------------------------------------
/faq/decision-tree-binary/calc_3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decision-tree-binary/calc_3.png
--------------------------------------------------------------------------------
/faq/decision-tree-binary/calc_5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decision-tree-binary/calc_5.png
--------------------------------------------------------------------------------
/faq/decision-tree-binary/calc_6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decision-tree-binary/calc_6.png
--------------------------------------------------------------------------------
/faq/decision-tree-binary/empty-classes.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decision-tree-binary/empty-classes.png
--------------------------------------------------------------------------------
/faq/decision-tree-binary/entropy.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decision-tree-binary/entropy.png
--------------------------------------------------------------------------------
/faq/decision-tree-binary/error.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decision-tree-binary/error.png
--------------------------------------------------------------------------------
/faq/decision-tree-binary/gini-impurity.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decision-tree-binary/gini-impurity.png
--------------------------------------------------------------------------------
/faq/decision-tree-binary/information-gain-2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decision-tree-binary/information-gain-2.png
--------------------------------------------------------------------------------
/faq/decision-tree-binary/information-gain.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decision-tree-binary/information-gain.png
--------------------------------------------------------------------------------
/faq/decision-tree-binary/overview-plot.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decision-tree-binary/overview-plot.png
--------------------------------------------------------------------------------
/faq/decision-tree-binary/split.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decision-tree-binary/split.png
--------------------------------------------------------------------------------
/faq/decisiontree-error-vs-entropy/Slide1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decisiontree-error-vs-entropy/Slide1.png
--------------------------------------------------------------------------------
/faq/decisiontree-error-vs-entropy/Slide2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decisiontree-error-vs-entropy/Slide2.png
--------------------------------------------------------------------------------
/faq/decisiontree-error-vs-entropy/Slide3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decisiontree-error-vs-entropy/Slide3.png
--------------------------------------------------------------------------------
/faq/decisiontree-error-vs-entropy/decisiontree-error-vs-entropy.pptx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decisiontree-error-vs-entropy/decisiontree-error-vs-entropy.pptx
--------------------------------------------------------------------------------
/faq/decisiontree-error-vs-entropy/entropy_annotated.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decisiontree-error-vs-entropy/entropy_annotated.png
--------------------------------------------------------------------------------
/faq/decisiontree-error-vs-entropy/entropy_eq.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decisiontree-error-vs-entropy/entropy_eq.png
--------------------------------------------------------------------------------
/faq/decisiontree-error-vs-entropy/entropy_plot.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decisiontree-error-vs-entropy/entropy_plot.png
--------------------------------------------------------------------------------
/faq/decisiontree-error-vs-entropy/error_eq.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decisiontree-error-vs-entropy/error_eq.png
--------------------------------------------------------------------------------
/faq/decisiontree-error-vs-entropy/error_plot.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decisiontree-error-vs-entropy/error_plot.png
--------------------------------------------------------------------------------
/faq/decisiontree-error-vs-entropy/ig.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decisiontree-error-vs-entropy/ig.png
--------------------------------------------------------------------------------
/faq/decisiontree-error-vs-entropy/ig_xp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/decisiontree-error-vs-entropy/ig_xp.png
--------------------------------------------------------------------------------
/faq/deep-learning-resources.md:
--------------------------------------------------------------------------------
1 | # What are some good books/papers for learning deep learning?
2 |
3 |
4 | A good overview and introduction is the recent deep learning review published in Nature (http://www.nature.com/nature/journal/v521/n7553/full/nature14539.html); it references a lot of useful literature to follow up on
5 |
6 | - LeCun, Yann, Yoshua Bengio, and Geoffrey Hinton. "Deep learning." Nature521.7553 (2015): 436-444.
7 |
8 |
9 | As a good textbook resource, I would like to recommend Yoshua Bengio's upcoming "Deep Learning" book. The book is freely accessible at: http://goodfeli.github.io/dlbook/
10 |
11 | - Bengio, Yoshua, Ian Goodfellow, and Aaron Courville. "Deep learning." An MIT Press book in preparation. Draft chapters available at http://www. iro. umontreal. ca/∼ bengioy/dlbook (2014).
12 |
--------------------------------------------------------------------------------
/faq/diff-perceptron-adaline-neuralnet/1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/diff-perceptron-adaline-neuralnet/1.png
--------------------------------------------------------------------------------
/faq/diff-perceptron-adaline-neuralnet/2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/diff-perceptron-adaline-neuralnet/2.png
--------------------------------------------------------------------------------
/faq/diff-perceptron-adaline-neuralnet/3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/diff-perceptron-adaline-neuralnet/3.png
--------------------------------------------------------------------------------
/faq/diff-perceptron-adaline-neuralnet/4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/diff-perceptron-adaline-neuralnet/4.png
--------------------------------------------------------------------------------
/faq/diff-perceptron-adaline-neuralnet/5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/diff-perceptron-adaline-neuralnet/5.png
--------------------------------------------------------------------------------
/faq/diff-perceptron-adaline-neuralnet/6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/diff-perceptron-adaline-neuralnet/6.png
--------------------------------------------------------------------------------
/faq/diff-perceptron-adaline-neuralnet/7.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/diff-perceptron-adaline-neuralnet/7.png
--------------------------------------------------------------------------------
/faq/diff-perceptron-adaline-neuralnet/8.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/diff-perceptron-adaline-neuralnet/8.png
--------------------------------------------------------------------------------
/faq/difference-deep-and-normal-learning/convnet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/difference-deep-and-normal-learning/convnet.png
--------------------------------------------------------------------------------
/faq/difference-deep-and-normal-learning/convolution.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/difference-deep-and-normal-learning/convolution.png
--------------------------------------------------------------------------------
/faq/difference-deep-and-normal-learning/mlp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/difference-deep-and-normal-learning/mlp.png
--------------------------------------------------------------------------------
/faq/dimensionality-reduction/lle.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/dimensionality-reduction/lle.png
--------------------------------------------------------------------------------
/faq/dimensionality-reduction/rbf-kpca.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/dimensionality-reduction/rbf-kpca.png
--------------------------------------------------------------------------------
/faq/dimensionality-reduction/swiss-roll.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/dimensionality-reduction/swiss-roll.png
--------------------------------------------------------------------------------
/faq/euclidean-distance.md:
--------------------------------------------------------------------------------
1 | # What is Euclidean distance in terms of machine learning?
2 |
3 |
4 | It is just a distance measure between a pair of samples *p* and *q* in an *n*-dimensional feature space:
5 |
6 | 
7 |
8 | For example, picture it as a "straight, connecting" line in a 2D feature space:
9 |
10 | 
11 |
12 | The Euclidean is often the "default" distance used in e.g., K-nearest neighbors (classification) or K-means (clustering) to find the "k closest points" of a particular sample point. Another prominent example is hierarchical clustering, agglomerative clustering (complete and single linkage) where you want to find the distance between clusters.
13 |
--------------------------------------------------------------------------------
/faq/euclidean-distance/eucl-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/euclidean-distance/eucl-1.png
--------------------------------------------------------------------------------
/faq/euclidean-distance/eucl-2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/euclidean-distance/eucl-2.png
--------------------------------------------------------------------------------
/faq/evaluate-a-model/evaluate_overview.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/evaluate-a-model/evaluate_overview.pdf
--------------------------------------------------------------------------------
/faq/evaluate-a-model/evaluate_overview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/evaluate-a-model/evaluate_overview.png
--------------------------------------------------------------------------------
/faq/evaluate-a-model/k-fold.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/evaluate-a-model/k-fold.png
--------------------------------------------------------------------------------
/faq/evaluate-a-model/nested-k-fold.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/evaluate-a-model/nested-k-fold.png
--------------------------------------------------------------------------------
/faq/inventing-deeplearning.md:
--------------------------------------------------------------------------------
1 | # Why did it take so long for deep networks to be invented?
2 |
3 | It's not that "deep networks" haven't been around in the 1960s, but the problem was how to train them. In the 1970s, backpropagation was "invented" or re-discovered -- I don't want to quote a single resource here not to offend any of the parties involved since this is a sensitive topic those days ... In any case, the problem was the "vanishing gradient," when gradient-based methods were used for learning the weights. It was observed that there was no gain going beyond 1-3 hidden layers.
4 |
5 |
6 | So back to the question: Deep network structures existed, but it was hard/impossible to train them appropriately. I'd say the 2 main reasons why this field experienced such a leap in the recent years
7 | are
8 |
9 |
10 | 1. availability of computing resources
11 | 2. clever ideas to pre-train a neural network
12 |
13 |
14 | The second point is what deep learning is all about; in a nutshell, we pre-train our deep neural networks using unsupervised learning, but this goes beyond the scope of the question ...
15 |
--------------------------------------------------------------------------------
/faq/issues-with-clustering/clusters_kmeans.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/issues-with-clustering/clusters_kmeans.png
--------------------------------------------------------------------------------
/faq/issues-with-clustering/clusters_unlabeled.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/issues-with-clustering/clusters_unlabeled.png
--------------------------------------------------------------------------------
/faq/issues-with-clustering/elbow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/issues-with-clustering/elbow.png
--------------------------------------------------------------------------------
/faq/issues-with-clustering/silhouette_bad.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/issues-with-clustering/silhouette_bad.png
--------------------------------------------------------------------------------
/faq/issues-with-clustering/silhouette_good.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/issues-with-clustering/silhouette_good.png
--------------------------------------------------------------------------------
/faq/large-num-features/concentric-circles.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/large-num-features/concentric-circles.png
--------------------------------------------------------------------------------
/faq/large-num-features/kpca-pc1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/large-num-features/kpca-pc1.png
--------------------------------------------------------------------------------
/faq/large-num-features/lle1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/large-num-features/lle1.png
--------------------------------------------------------------------------------
/faq/large-num-features/lle2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/large-num-features/lle2.png
--------------------------------------------------------------------------------
/faq/large-num-features/pca-pc1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/large-num-features/pca-pc1.png
--------------------------------------------------------------------------------
/faq/large-num-features/swiss-roll.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/large-num-features/swiss-roll.png
--------------------------------------------------------------------------------
/faq/lazy-knn.md:
--------------------------------------------------------------------------------
1 | # Why is Nearest Neighbor a Lazy Algorithm?
2 |
3 | Although, Nearest neighbor algorithms, for instance, the K-Nearest Neighbors (K-NN) for classification, are very "simple" algorithms, that's not why they are called *lazy* ;). K-NN is a lazy learner because it doesn't learn a discriminative function from the training data but "memorizes" the training dataset instead.
4 |
5 | For example, the logistic regression algorithm learns its model weights (parameters) during training time. In contrast, there is no training time in K-NN. Although this may sound very convenient, this property doesn't come without a cost: The "prediction" step in K-NN is relatively expensive! Each time we want to make a prediction, K-NN is searching for the nearest neighbor(s) in the entire training set! (Note that there are certain tricks such as BallTrees and KDtrees to speed this up a bit.)
6 |
7 | To summarize: An eager learner has a model fitting or training step. A lazy learner does not have a training phase.
8 |
--------------------------------------------------------------------------------
/faq/lda-vs-pca.md:
--------------------------------------------------------------------------------
1 | # What is the difference between LDA and PCA for dimensionality reduction?
2 |
3 | Both LDA and PCA are linear transformation techniques: LDA is a supervised whereas PCA is unsupervised -- PCA ignores class labels.
4 |
5 | We can picture PCA as a technique that finds the directions of maximal variance:
6 |
7 | 
8 |
9 | In contrast to PCA, LDA attempts to find a feature subspace that maximizes class separability (note that LD 2 would be a very bad linear discriminant in the figure above).
10 |
11 | 
12 |
13 |
14 | Remember that LDA makes assumptions about normally distributed classes and equal class covariances.
15 | If you are interested in an empirical comparison: A. M. Martinez and A. C. Kak. PCA versus LDA. Pattern Analysis and Machine Intelligence, IEEE Transactions on, 23(2):228–233, 2001). (PCA tends to result in better classification results in an image recognition task if the number of samples for a given class was relatively small.)
16 |
--------------------------------------------------------------------------------
/faq/lda-vs-pca/lda.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/lda-vs-pca/lda.png
--------------------------------------------------------------------------------
/faq/lda-vs-pca/pca.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/lda-vs-pca/pca.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/1.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/10.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/10.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/11.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/11.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/12.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/12.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/13.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/13.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/14.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/14.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/15.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/15.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/16.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/16.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/17.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/17.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/18.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/18.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/19.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/19.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/2.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/20.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/20.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/21.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/21.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/22.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/22.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/23.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/23.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/3.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/4.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/5.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/6.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/7.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/7.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/8.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/8.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/9.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/9.png
--------------------------------------------------------------------------------
/faq/linear-gradient-derivative/regression-vs-adaline.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/linear-gradient-derivative/regression-vs-adaline.png
--------------------------------------------------------------------------------
/faq/logistic-analytical.md:
--------------------------------------------------------------------------------
1 | # Is there an analytical solution to Logistic Regression similar to the Normal Equation for Linear Regression?
2 |
3 | Unfortunately, there is no closed-form solution for maximizing the log-likelihood (or minimizing the inverse, the logistic cost function); at least it has not been found, yet.
4 |
5 | There's the exception where you only have 2 obervations, and there is this paper
6 |
7 | *Lipovetsky, Stan. ["Analytical closed-form solution for binary logit regression by categorical predictors."](http://www.tandfonline.com/doi/abs/10.1080/02664763.2014.932760) Journal of Applied Statistics 42.1 (2015): 37-49. (Analytical closed-form solution for binary logit regression by categorical predictors)*
8 |
9 | which "shows that for categorical explanatory variables, it is possible to present the solution in the analytical closed-form formulae."
10 | The problem is that the logistic sigmoid function is non-linear -- in case of linear regression, you are assuming independent Gaussian noise.
11 |
--------------------------------------------------------------------------------
/faq/logistic-boosting.md:
--------------------------------------------------------------------------------
1 | # Do bagging and boosting can be used with logistic regression?
2 |
3 | I am not sure if bagging would make much sense for logistic regression -- in bagging, we reduce the variance of the deep decision tree models that overfit the training data, which wouldn't really apply to logistic regression.
4 |
5 | Boosting could work though, however, I think that "stacking" would be a better approach here. Stacking would be more "powerful" since we don't use a pre-specified equation to adjust the weight, rather, we train a meta-classifier to learn the optimal weights to combine the models.
6 |
7 |
8 | Here's one of the many interesting, related papers, I recommend you to check out :)
9 |
10 | - "Is Combining Classifiers with Stacking Better than Selecting the Best One?"
11 |
--------------------------------------------------------------------------------
/faq/logistic-why-sigmoid/1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logistic-why-sigmoid/1.png
--------------------------------------------------------------------------------
/faq/logistic-why-sigmoid/2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logistic-why-sigmoid/2.png
--------------------------------------------------------------------------------
/faq/logistic-why-sigmoid/3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logistic-why-sigmoid/3.png
--------------------------------------------------------------------------------
/faq/logistic-why-sigmoid/4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logistic-why-sigmoid/4.png
--------------------------------------------------------------------------------
/faq/logistic-why-sigmoid/5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logistic-why-sigmoid/5.png
--------------------------------------------------------------------------------
/faq/logistic-why-sigmoid/6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logistic-why-sigmoid/6.png
--------------------------------------------------------------------------------
/faq/logistic-why-sigmoid/7.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logistic-why-sigmoid/7.png
--------------------------------------------------------------------------------
/faq/logistic_regression_linear/1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logistic_regression_linear/1.png
--------------------------------------------------------------------------------
/faq/logistic_regression_linear/2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logistic_regression_linear/2.png
--------------------------------------------------------------------------------
/faq/logistic_regression_linear/3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logistic_regression_linear/3.png
--------------------------------------------------------------------------------
/faq/logistic_regression_linear/4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logistic_regression_linear/4.png
--------------------------------------------------------------------------------
/faq/logisticregr-neuralnet/log-tanh.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logisticregr-neuralnet/log-tanh.png
--------------------------------------------------------------------------------
/faq/logisticregr-neuralnet/mlp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logisticregr-neuralnet/mlp.png
--------------------------------------------------------------------------------
/faq/logisticregr-neuralnet/onehot.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logisticregr-neuralnet/onehot.png
--------------------------------------------------------------------------------
/faq/logisticregr-neuralnet/schematic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logisticregr-neuralnet/schematic.png
--------------------------------------------------------------------------------
/faq/logisticregr-neuralnet/sigmoid.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logisticregr-neuralnet/sigmoid.png
--------------------------------------------------------------------------------
/faq/logisticregr-neuralnet/softmax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logisticregr-neuralnet/softmax.png
--------------------------------------------------------------------------------
/faq/logisticregr-neuralnet/unconvex.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/logisticregr-neuralnet/unconvex.png
--------------------------------------------------------------------------------
/faq/median-vs-mean.md:
--------------------------------------------------------------------------------
1 | # When should one use median, as opposed to the mean or average?
2 |
3 | It really depends on the distribution of the data and the question you are trying to address.
4 |
5 | Consider a symmetric distribution (here, I've drawn 10,000 random samples from a standard normal distribution):
6 |
7 | 
8 |
9 | In this case, the median and mean will be very similar (mean≈0.00337, median≈0.01690). In fact, the median and mean will be the same if your data sample is perfectly symmetrical distributed, for example, consider [1, 3, 5] or [1, 3, 3, 5].
10 |
11 | Now, if you data is skewed, you are likely more interested in computing the median, which is less susceptible to outliers and extreme values. Let's consider a classic examples "salaries." Here, I plotted [FGCU salary dataset from OpenData](https://opendata.socrata.com/dataset/FGCU-salary-dataset/fjqw-ymup):
12 |
13 | 
14 |
15 | As we can see, there is a substantial difference between the mean and median value. Here, the mean picks up the relatively high but infrequent salaries at > 15,000.
16 |
17 | Again, it depends on the question you are asking of the data, however, if you question is "what is the average salary" in terms of "what is the typical salary of an employee," then median would be a much better measure than the mean.
18 |
--------------------------------------------------------------------------------
/faq/median-vs-mean/salary.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/median-vs-mean/salary.png
--------------------------------------------------------------------------------
/faq/median-vs-mean/std-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/median-vs-mean/std-normal.png
--------------------------------------------------------------------------------
/faq/mentor.md:
--------------------------------------------------------------------------------
1 | # How important do you think having a mentor is to the learning process?
2 |
3 | I guess it really depends on what type of learner you are. From what I understand, a mentor is like a "personal trainer," someone who gives you homework, tells you what books to read, etc. (in contrast to a teacher or professor who teaches a whole class at once). I think it is important to have friends who share similar interests to bounce of ideas, and I think it is important to know someone more knowledgeable than you who you could ask questions for your personal growth (e.g., a Prof who supervises your Ph.D. thesis would be such a person). However, I am not sure how important a "mentor" is for technical questions -- I think that's the 1-person equivalent of an answer poll via cross-validated or Quora. Anyways, I think a mentor may be a nice thing to have for certain people, but I wouldn't say everyone needs a dedicated "mentor."
4 |
--------------------------------------------------------------------------------
/faq/missing-data.md:
--------------------------------------------------------------------------------
1 | # What are some common approaches for dealing with missing data?
2 |
3 | Many different approaches exist for dealing with missing values; I'd roughly categorize our options into a) deletion and b) imputation techniques.
4 |
5 | ## a) Deletion
6 |
7 | 1) We have a lot of training samples and can afford deleting some of those. Here, we can simply remove samples with missing feature values from the dataset entirely.
8 |
9 | 2) We have a large number of feature columns and some of them are redundant. Relatively many samples have a missing feature value in a certain column. In this scenario, it may be a good idea to remove these feature columns with missing values entirely.
10 |
11 | ## b) Imputation
12 |
13 | If we can't afford deleting data points, we could use imputation techniques to "guess" placeholder values from the remaining data points.
14 |
15 | 1) The simplest imputation technique may be the replacement of a missing feature value by its feature column's mean (median or mode).
16 |
17 | 2) Instead of replacing a feature value by its column mean, we can only consider the k-nearest neighbors of this datapoint for computing the mean (median or mode) -- we identify the neighbors based on the remaining feature columns that don't have missing values.
18 |
--------------------------------------------------------------------------------
/faq/ml-curriculum/bengio.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-curriculum/bengio.png
--------------------------------------------------------------------------------
/faq/ml-curriculum/bishop.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-curriculum/bishop.jpeg
--------------------------------------------------------------------------------
/faq/ml-curriculum/domingos.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-curriculum/domingos.png
--------------------------------------------------------------------------------
/faq/ml-curriculum/duda.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-curriculum/duda.jpg
--------------------------------------------------------------------------------
/faq/ml-curriculum/ng.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-curriculum/ng.png
--------------------------------------------------------------------------------
/faq/ml-curriculum/raschka.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-curriculum/raschka.jpeg
--------------------------------------------------------------------------------
/faq/ml-curriculum/tan.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-curriculum/tan.jpeg
--------------------------------------------------------------------------------
/faq/ml-curriculum/three.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-curriculum/three.png
--------------------------------------------------------------------------------
/faq/ml-curriculum/tibshirani.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-curriculum/tibshirani.jpeg
--------------------------------------------------------------------------------
/faq/ml-examples/fb.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-examples/fb.png
--------------------------------------------------------------------------------
/faq/ml-examples/google.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-examples/google.png
--------------------------------------------------------------------------------
/faq/ml-examples/hiv-protease.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-examples/hiv-protease.png
--------------------------------------------------------------------------------
/faq/ml-examples/letter.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-examples/letter.jpg
--------------------------------------------------------------------------------
/faq/ml-examples/stars.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-examples/stars.jpg
--------------------------------------------------------------------------------
/faq/ml-examples/stock-market.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-examples/stock-market.png
--------------------------------------------------------------------------------
/faq/ml-python-communities.md:
--------------------------------------------------------------------------------
1 | # Where are the best online communities centered around data science/machine learning or python?
2 |
3 | I think [Twitter](https://twitter.com/rasbt) is great to stay in touch and see what other people are up to, and to share news of course. [Cross-validated](http://stats.stackexchange.com) & [Quora](https://www.quora.com/topic/Machine-Learning) are good websites to ask specific questions and collect multiple opinions about a topic. There's also a [machine learning group on Google+](https://plus.google.com/communities/107785538899595981479) that has a lot of members, but is not that active anymore I fear. The [MachineLearning subreddit](https://www.reddit.com/r/MachineLearning/) is another nice place to discuss certain news and articles.
4 |
--------------------------------------------------------------------------------
/faq/ml-solvable/bias-variance.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-solvable/bias-variance.png
--------------------------------------------------------------------------------
/faq/ml-solvable/learning_curve.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-solvable/learning_curve.png
--------------------------------------------------------------------------------
/faq/ml-solvable/param_curve.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/ml-solvable/param_curve.png
--------------------------------------------------------------------------------
/faq/multiclass-metric/conf_mat.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/multiclass-metric/conf_mat.png
--------------------------------------------------------------------------------
/faq/multiclass-metric/macro.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/multiclass-metric/macro.png
--------------------------------------------------------------------------------
/faq/multiclass-metric/mcc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/multiclass-metric/mcc.png
--------------------------------------------------------------------------------
/faq/multiclass-metric/micro.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/multiclass-metric/micro.png
--------------------------------------------------------------------------------
/faq/multiclass-metric/pre-rec.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/multiclass-metric/pre-rec.png
--------------------------------------------------------------------------------
/faq/naive-bayes-boundary.md:
--------------------------------------------------------------------------------
1 | # What is the decision boundary for Naive Bayes?
2 |
3 |
4 | It's a (piecewise) quadratic decision boundary for the Gaussian model. The multinomial model has a linear boundary.
5 | Below, I plotted some examples:
6 |
7 | 1) UCI Wine Dataset
8 |
9 | 
10 |
11 | 2) An XOR toy dataset
12 |
13 | 
14 |
--------------------------------------------------------------------------------
/faq/naive-bayes-boundary/gaussian_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-bayes-boundary/gaussian_1.png
--------------------------------------------------------------------------------
/faq/naive-bayes-boundary/gaussian_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-bayes-boundary/gaussian_2.png
--------------------------------------------------------------------------------
/faq/naive-bayes-vartypes/bayes-theorem-in-words.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-bayes-vartypes/bayes-theorem-in-words.png
--------------------------------------------------------------------------------
/faq/naive-bayes-vartypes/bayes-theorem-notation.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-bayes-vartypes/bayes-theorem-notation.png
--------------------------------------------------------------------------------
/faq/naive-bayes-vartypes/bayes-theorem.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-bayes-vartypes/bayes-theorem.png
--------------------------------------------------------------------------------
/faq/naive-bayes-vartypes/combined.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-bayes-vartypes/combined.png
--------------------------------------------------------------------------------
/faq/naive-bayes-vartypes/gaussian-likelihood.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-bayes-vartypes/gaussian-likelihood.png
--------------------------------------------------------------------------------
/faq/naive-bayes-vartypes/likelihood-bernoulli.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-bayes-vartypes/likelihood-bernoulli.png
--------------------------------------------------------------------------------
/faq/naive-bayes-vartypes/multi-variate-bernoulli.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-bayes-vartypes/multi-variate-bernoulli.png
--------------------------------------------------------------------------------
/faq/naive-bayes-vartypes/naive-bayes-decision.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-bayes-vartypes/naive-bayes-decision.png
--------------------------------------------------------------------------------
/faq/naive-bayes-vartypes/naive-bayes-likelihood.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-bayes-vartypes/naive-bayes-likelihood.png
--------------------------------------------------------------------------------
/faq/naive-bayes-vartypes/naive-bayes-likelihood_shorter.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-bayes-vartypes/naive-bayes-likelihood_shorter.png
--------------------------------------------------------------------------------
/faq/naive-naive-bayes.md:
--------------------------------------------------------------------------------
1 | # Why is the Naive Bayes Classifier naive?
2 |
3 | Let's start by taking a quick look at the Bayes' Theorem:
4 |
5 | 
6 |
7 | In context of pattern classification, we can express it as
8 |
9 | 
10 |
11 | 
12 |
13 | If we use the Bayes Theorem in classification, our goal (or objective function) is to maximize the posterior probability
14 |
15 | 
16 |
17 | Now, let's talk a bit more about the individual components. The priors are representing our expert (or any other prior) knowledge; in practice, the priors are often estimated via MLE (computed as class frequencies). The evidence term cancels because it is constant for all classes.
18 |
19 | Moving on to the "naive" part in the Naive Bayes Classifier: What makes it "naive" is that we compute the conditional probability (sometimes also called likelihoods) as the product of the individual probabilities for each feature:
20 |
21 | 
22 |
23 | Since this assumption (the absolute independence of features) is probably never met in practice, it's the truly "naive" part in naive Bayes.
24 |
--------------------------------------------------------------------------------
/faq/naive-naive-bayes/bayes-theorem-english.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-naive-bayes/bayes-theorem-english.png
--------------------------------------------------------------------------------
/faq/naive-naive-bayes/bayes_theorem.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-naive-bayes/bayes_theorem.png
--------------------------------------------------------------------------------
/faq/naive-naive-bayes/decision_rule.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-naive-bayes/decision_rule.png
--------------------------------------------------------------------------------
/faq/naive-naive-bayes/let.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-naive-bayes/let.png
--------------------------------------------------------------------------------
/faq/naive-naive-bayes/likelihood.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/naive-naive-bayes/likelihood.png
--------------------------------------------------------------------------------
/faq/neuralnet-error/approx-grad-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/neuralnet-error/approx-grad-1.png
--------------------------------------------------------------------------------
/faq/neuralnet-error/approx-grad-2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/neuralnet-error/approx-grad-2.png
--------------------------------------------------------------------------------
/faq/neuralnet-error/approx-grad-3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/neuralnet-error/approx-grad-3.png
--------------------------------------------------------------------------------
/faq/neuralnet-error/approx-grad-4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/neuralnet-error/approx-grad-4.png
--------------------------------------------------------------------------------
/faq/neuralnet-error/momentum.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/neuralnet-error/momentum.png
--------------------------------------------------------------------------------
/faq/neuralnet-error/standardizing.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/neuralnet-error/standardizing.png
--------------------------------------------------------------------------------
/faq/num-support-vectors.md:
--------------------------------------------------------------------------------
1 | # When training an SVM classifier, is it better to have a large or small number of support vectors?
2 |
3 |
4 | Unfortunately, like so often in machine learning applications, it really depends on the dataset. If we train an RBF kernel SVM, we will typically end up with more support vectors than in a linear model. If our data is linearly separable, the latter may be better, and if that's not the case, the former may be better.
5 |
6 | Also, we have to differentiate between computational efficiency and generalization performance. If we increase the number of support vectors, our classification becomes more "expensive", especially in kernel SVM where we have to recalculate the distances between every new sample and the entire training set.
7 |
8 |
9 | I'd say the best way to tackle the predictive performance problem is simply to evaluate the model, plot learning curves, do k-fold and/or cross validation, and see what works best on our given dataset.
10 |
--------------------------------------------------------------------------------
/faq/open-source.md:
--------------------------------------------------------------------------------
1 | # At what point should one start contributing to open source?
2 |
3 | Please don't feel pressured to contribute to open source if this is not your thing -- I see it more as an opportunity to learn and "give back" but it is certainly not a "duty" :).
4 |
5 | > ... small tasks like fixing typos [...] time could be spent learning instead
6 |
7 | I'd say it depends. I think contributing to open-source projects shouldn't be all about personal benefits, and expanding/fixing documentation where it is useful is also valuable for a project. Eventually, it is up to you where you want to be on the spectrum between "how does this benefit me personally" and "would this help the community and the people who put so much effort into the things that I am using daily for free." -- it's certainly not a black or white decision, and there is no right or wrong :)
8 |
9 | Btw. depending on your experience level, "fixing typos" can be a valuable learning experience as well. For instance, doing "data science" is not only about analyzing data, but communications skills and team skills are important as well. If you are not familiar with version control, see fixing typos as an opportunity to learn about it or practice working with certain frameworks/workflows.
10 |
--------------------------------------------------------------------------------
/faq/overfitting/learning_curve_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/overfitting/learning_curve_1.png
--------------------------------------------------------------------------------
/faq/pca-scaling/1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pca-scaling/1.png
--------------------------------------------------------------------------------
/faq/pca-scaling/10.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pca-scaling/10.png
--------------------------------------------------------------------------------
/faq/pca-scaling/11.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pca-scaling/11.png
--------------------------------------------------------------------------------
/faq/pca-scaling/2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pca-scaling/2.png
--------------------------------------------------------------------------------
/faq/pca-scaling/3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pca-scaling/3.png
--------------------------------------------------------------------------------
/faq/pca-scaling/4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pca-scaling/4.png
--------------------------------------------------------------------------------
/faq/pca-scaling/5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pca-scaling/5.png
--------------------------------------------------------------------------------
/faq/pca-scaling/6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pca-scaling/6.png
--------------------------------------------------------------------------------
/faq/pca-scaling/7.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pca-scaling/7.png
--------------------------------------------------------------------------------
/faq/pca-scaling/8.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pca-scaling/8.png
--------------------------------------------------------------------------------
/faq/pca-scaling/9.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pca-scaling/9.png
--------------------------------------------------------------------------------
/faq/pearson-r-vs-linear-regr/covariance.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pearson-r-vs-linear-regr/covariance.png
--------------------------------------------------------------------------------
/faq/pearson-r-vs-linear-regr/example-1-fit.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pearson-r-vs-linear-regr/example-1-fit.png
--------------------------------------------------------------------------------
/faq/pearson-r-vs-linear-regr/example-1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pearson-r-vs-linear-regr/example-1.png
--------------------------------------------------------------------------------
/faq/pearson-r-vs-linear-regr/example-2-fit.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pearson-r-vs-linear-regr/example-2-fit.png
--------------------------------------------------------------------------------
/faq/pearson-r-vs-linear-regr/example-2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pearson-r-vs-linear-regr/example-2.png
--------------------------------------------------------------------------------
/faq/pearson-r-vs-linear-regr/intercept.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pearson-r-vs-linear-regr/intercept.png
--------------------------------------------------------------------------------
/faq/pearson-r-vs-linear-regr/pearson.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pearson-r-vs-linear-regr/pearson.png
--------------------------------------------------------------------------------
/faq/pearson-r-vs-linear-regr/sigma.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pearson-r-vs-linear-regr/sigma.png
--------------------------------------------------------------------------------
/faq/pearson-r-vs-linear-regr/slope.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pearson-r-vs-linear-regr/slope.png
--------------------------------------------------------------------------------
/faq/pearson-r-vs-linear-regr/slope_r.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pearson-r-vs-linear-regr/slope_r.png
--------------------------------------------------------------------------------
/faq/pearson-r-vs-linear-regr/slope_rewrite.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pearson-r-vs-linear-regr/slope_rewrite.png
--------------------------------------------------------------------------------
/faq/pearson-r-vs-linear-regr/standardize.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/pearson-r-vs-linear-regr/standardize.png
--------------------------------------------------------------------------------
/faq/probablistic-logistic-regression/1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/probablistic-logistic-regression/1.png
--------------------------------------------------------------------------------
/faq/probablistic-logistic-regression/2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/probablistic-logistic-regression/2.png
--------------------------------------------------------------------------------
/faq/probablistic-logistic-regression/3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/probablistic-logistic-regression/3.png
--------------------------------------------------------------------------------
/faq/probablistic-logistic-regression/4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/probablistic-logistic-regression/4.png
--------------------------------------------------------------------------------
/faq/probablistic-logistic-regression/5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/probablistic-logistic-regression/5.png
--------------------------------------------------------------------------------
/faq/probablistic-logistic-regression/6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/probablistic-logistic-regression/6.png
--------------------------------------------------------------------------------
/faq/probablistic-logistic-regression/7.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/probablistic-logistic-regression/7.png
--------------------------------------------------------------------------------
/faq/probablistic-logistic-regression/8.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/probablistic-logistic-regression/8.png
--------------------------------------------------------------------------------
/faq/probablistic-logistic-regression/9.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/probablistic-logistic-regression/9.png
--------------------------------------------------------------------------------
/faq/py2py3.md:
--------------------------------------------------------------------------------
1 | # Which version of Python was used in the code examples?
2 |
3 | I wrote all code examples in 3.4. I tried to also make sure that everything works fine with Python 2.7, however, I stopped testing the code on Python 2.7 halfway through the book. The reason is that I really don't think that it is really crucial which Python version is being used since most of the libraries towards supporting both Python 2.7 and 3.4 anyways.
4 |
5 | Throughout the book, we will also implement our own machine learning algorithms from scratch (linear classifiers, ensemble classifiers, feature selection, and neural networks), and here I paid special attention that it works for Python 2.7 as well.
6 |
7 | I think the only parts where Py27 may have a disadvantage is the sentiment analysis chapter due to the quirky Unicode handling. However, I added notes and comments here and there so that you could get along with Python 2.7 just fine I hope!
8 |
9 | Anyways, I think the real focus of this book is to learn about the important concepts in Machine Learning, and how to write code to put it to action. Thus, after reading the book, you will hopefully find that you are interested in the bigger questions and be fascinated by the possibilities Python offers to get your analysis done!
10 |
--------------------------------------------------------------------------------
/faq/regularized-logistic-regression-performance/l2-term.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/regularized-logistic-regression-performance/l2-term.png
--------------------------------------------------------------------------------
/faq/regularized-logistic-regression-performance/regularized.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/regularized-logistic-regression-performance/regularized.png
--------------------------------------------------------------------------------
/faq/regularized-logistic-regression-performance/unregularized.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/regularized-logistic-regression-performance/unregularized.png
--------------------------------------------------------------------------------
/faq/return_self_idiom.md:
--------------------------------------------------------------------------------
1 | # What is the purpose of the `return self` idioms in your code examples?
2 |
3 | Many (if not all) of the object-oriented implementations in my code examples return `self` in their respective calls -- and scikit-learn does this, too! So, what is the rational behind a method that returns the the object itself? The answer is a rather simple one: "Chaining," which enables us to concatenate operations more conveniently (and efficiently) by feeding the answer of an operations into the next.
4 |
5 | For example, an implementation such as
6 |
7 | class Perceptron(object):
8 | def __init__(self, …):
9 | …
10 |
11 | def fit(self, …):
12 | return self
13 |
14 | def predict(self, …):
15 | return self
16 |
17 | would allow us to write a compact notation such as
18 |
19 | prediction = Perceptron().fit(X, y).predict(X)
20 |
21 | in one line of code instead of
22 |
23 | p = Perceptron()
24 | p.fit(X, y)
25 | prediction = p.predict(X)
26 |
--------------------------------------------------------------------------------
/faq/select_svm_kernels/1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/select_svm_kernels/1.png
--------------------------------------------------------------------------------
/faq/select_svm_kernels/2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/select_svm_kernels/2.png
--------------------------------------------------------------------------------
/faq/select_svm_kernels/3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/select_svm_kernels/3.png
--------------------------------------------------------------------------------
/faq/select_svm_kernels/4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/select_svm_kernels/4.png
--------------------------------------------------------------------------------
/faq/select_svm_kernels/5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/select_svm_kernels/5.png
--------------------------------------------------------------------------------
/faq/softmax.md:
--------------------------------------------------------------------------------
1 | # What exactly is the "softmax and the multinomial logistic loss" in the context of machine learning?
2 |
3 | The softmax function is simply a generalization of the logistic function that allows us to compute meaningful class-probabilities in multi-class settings (multinomial logistic regression). In softmax, we compute the probability that a particular sample (with net input z) belongs to the *i*th class using a normalization term in the denominator that is the sum of all *M* linear functions:
4 |
5 | 
6 |
7 | In contrast, the logistic function:
8 |
9 | 
10 |
11 | And for completeness, we define the net input as
12 |
13 | 
14 |
15 | where the weight coefficients of your model are stored as vector "w" and "x" is the feature vector of your sample.
16 |
--------------------------------------------------------------------------------
/faq/softmax/logistic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax/logistic.png
--------------------------------------------------------------------------------
/faq/softmax/net_input.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax/net_input.png
--------------------------------------------------------------------------------
/faq/softmax/softmax_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax/softmax_1.png
--------------------------------------------------------------------------------
/faq/softmax_regression/1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/1.png
--------------------------------------------------------------------------------
/faq/softmax_regression/10.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/10.png
--------------------------------------------------------------------------------
/faq/softmax_regression/11.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/11.png
--------------------------------------------------------------------------------
/faq/softmax_regression/12.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/12.png
--------------------------------------------------------------------------------
/faq/softmax_regression/13.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/13.png
--------------------------------------------------------------------------------
/faq/softmax_regression/14.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/14.png
--------------------------------------------------------------------------------
/faq/softmax_regression/15.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/15.png
--------------------------------------------------------------------------------
/faq/softmax_regression/2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/2.png
--------------------------------------------------------------------------------
/faq/softmax_regression/3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/3.png
--------------------------------------------------------------------------------
/faq/softmax_regression/4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/4.png
--------------------------------------------------------------------------------
/faq/softmax_regression/5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/5.png
--------------------------------------------------------------------------------
/faq/softmax_regression/6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/6.png
--------------------------------------------------------------------------------
/faq/softmax_regression/7.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/7.png
--------------------------------------------------------------------------------
/faq/softmax_regression/8.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/8.png
--------------------------------------------------------------------------------
/faq/softmax_regression/9.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/9.png
--------------------------------------------------------------------------------
/faq/softmax_regression/logistic_regression_schematic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/softmax_regression/logistic_regression_schematic.png
--------------------------------------------------------------------------------
/faq/svm_for_categorical_data/onehot-color.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/svm_for_categorical_data/onehot-color.png
--------------------------------------------------------------------------------
/faq/tensorflow-vs-scikitlearn/scikit-softmax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/tensorflow-vs-scikitlearn/scikit-softmax.png
--------------------------------------------------------------------------------
/faq/tensorflow-vs-scikitlearn/tf_cost.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/tensorflow-vs-scikitlearn/tf_cost.png
--------------------------------------------------------------------------------
/faq/tensorflow-vs-scikitlearn/tf_softmax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/tensorflow-vs-scikitlearn/tf_softmax.png
--------------------------------------------------------------------------------
/faq/version.md:
--------------------------------------------------------------------------------
1 | # Which book version/format would you recommend?
2 |
3 | Personally, I prefer Amazon when it comes to print versions of books (probably because they ship pretty quickly). For ebooks, I really have no preference: Google books, Amazon, or iBooks -- they come all with pretty good reading apps for your tablet or computer.
4 |
5 | I really do not want to advertise any platform here, but I think it would not be a bad idea to consider getting it from the publisher directly, since you'd get a DRM-free .epub version for your favorite reading app plus the PDF. And adding the print version is only slightly more expensive. Unfortunately, the figures in the print version will be in grayscale, so it's probably nicer to take a look at the digital options.
6 |
7 | But no matter which platform you choose: I will make sure that you get the code examples most conveniently -- I will upload them here on GitHub; you won't need to create an account at PACKT just to download the code examples :).
8 |
--------------------------------------------------------------------------------
/faq/visual-backpropagation/backpropagation.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/visual-backpropagation/backpropagation.png
--------------------------------------------------------------------------------
/faq/visual-backpropagation/chain_rule_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/visual-backpropagation/chain_rule_1.png
--------------------------------------------------------------------------------
/faq/visual-backpropagation/chain_rule_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/visual-backpropagation/chain_rule_2.png
--------------------------------------------------------------------------------
/faq/visual-backpropagation/forward-propagation.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/visual-backpropagation/forward-propagation.png
--------------------------------------------------------------------------------
/faq/visual-backpropagation/nonconvex-cost.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/visual-backpropagation/nonconvex-cost.png
--------------------------------------------------------------------------------
/faq/why-python/automation.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/why-python/automation.png
--------------------------------------------------------------------------------
/faq/why-python/heatmap.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/why-python/heatmap.png
--------------------------------------------------------------------------------
/faq/why-python/ipython_notebook.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/why-python/ipython_notebook.png
--------------------------------------------------------------------------------
/faq/why-python/julia_benchmark.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/why-python/julia_benchmark.png
--------------------------------------------------------------------------------
/faq/why-python/python.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/why-python/python.png
--------------------------------------------------------------------------------
/faq/why-python/revor.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/why-python/revor.png
--------------------------------------------------------------------------------
/faq/why-python/spectrum.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/why-python/spectrum.jpg
--------------------------------------------------------------------------------
/faq/why-python/the_general_problem.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/why-python/the_general_problem.png
--------------------------------------------------------------------------------
/faq/why-python/tiobe.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/faq/why-python/tiobe.png
--------------------------------------------------------------------------------
/images/CRBadgeNotableBook.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/CRBadgeNotableBook.jpg
--------------------------------------------------------------------------------
/images/check_env.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/check_env.png
--------------------------------------------------------------------------------
/images/cover_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/cover_1.png
--------------------------------------------------------------------------------
/images/equation-ref-logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/equation-ref-logo.png
--------------------------------------------------------------------------------
/images/ml-overview.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/ml-overview.jpg
--------------------------------------------------------------------------------
/images/mlxtend_logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/mlxtend_logo.png
--------------------------------------------------------------------------------
/images/pymle-cover_cn.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/pymle-cover_cn.jpg
--------------------------------------------------------------------------------
/images/pymle-cover_cn_mainland.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/pymle-cover_cn_mainland.jpg
--------------------------------------------------------------------------------
/images/pymle-cover_de.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/pymle-cover_de.jpg
--------------------------------------------------------------------------------
/images/pymle-cover_de_old.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/pymle-cover_de_old.jpg
--------------------------------------------------------------------------------
/images/pymle-cover_it.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/pymle-cover_it.jpg
--------------------------------------------------------------------------------
/images/pymle-cover_jp.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/pymle-cover_jp.jpg
--------------------------------------------------------------------------------
/images/pymle-cover_kr.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/pymle-cover_kr.jpg
--------------------------------------------------------------------------------
/images/pymle-cover_pl.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/pymle-cover_pl.jpg
--------------------------------------------------------------------------------
/images/pymle-cover_ru.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/pymle-cover_ru.jpg
--------------------------------------------------------------------------------
/images/pymle_amzn.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/pymle_amzn.png
--------------------------------------------------------------------------------
/images/pymle_cover.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/pymle_cover.jpg
--------------------------------------------------------------------------------
/images/pymle_cover_double_small.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/pymle_cover_double_small.jpg
--------------------------------------------------------------------------------
/images/pymle_cover_small.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/pymle_cover_small.jpg
--------------------------------------------------------------------------------
/images/scipy2016.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/rasbt/python-machine-learning-book/903209f79735249613da5e2019be06d1d6a09e2c/images/scipy2016.jpg
--------------------------------------------------------------------------------