Search icon CANCEL
Subscription
0
Cart icon
Cart
Close icon
You have no products in your basket yet
Save more on your purchases!
Savings automatically calculated. No voucher code required
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Hands-On Ensemble Learning with Python

You're reading from  Hands-On Ensemble Learning with Python

Product type Book
Published in Jul 2019
Publisher Packt
ISBN-13 9781789612851
Pages 298 pages
Edition 1st Edition
Languages
Authors (2):
George Kyriakides George Kyriakides
Profile icon George Kyriakides
Konstantinos G. Margaritis Konstantinos G. Margaritis
Profile icon Konstantinos G. Margaritis
View More author details
Toc

Table of Contents (20) Chapters close

Preface 1. Section 1: Introduction and Required Software Tools
2. A Machine Learning Refresher 3. Getting Started with Ensemble Learning 4. Section 2: Non-Generative Methods
5. Voting 6. Stacking 7. Section 3: Generative Methods
8. Bagging 9. Boosting 10. Random Forests 11. Section 4: Clustering
12. Clustering 13. Section 5: Real World Applications
14. Classifying Fraudulent Transactions 15. Predicting Bitcoin Prices 16. Evaluating Sentiment on Twitter 17. Recommending Movies with Keras 18. Clustering World Happiness 19. Another Book You May Enjoy

Voting

In this section, we will try to classify the dataset by using voting ensembles. For our initial ensemble, we will utilize a Naive Bayes classifier, a logistic regression, and a decision tree. This will be implemented in two parts, first by testing each base learner itself and then combining the base learners into an ensemble.

Testing the base learners

To test the base learners, we will benchmark the base learners by themselves, which will help us gauge how well they perform on their own. In order to do so, first, we load the libraries and dataset and then split the data with 70% in the train set and 30% in the test set. We use pandas in order to easily import the CSV. Our goal is to train and evaluate each individual...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €14.99/month. Cancel anytime