Search icon CANCEL
Subscription
0
Cart icon
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
Machine Learning With Go

You're reading from  Machine Learning With Go

Product type Book
Published in Sep 2017
Publisher Packt
ISBN-13 9781785882104
Pages 304 pages
Edition 1st Edition
Languages

Table of Contents (11) Chapters

Preface 1. Gathering and Organizing Data 2. Matrices, Probability, and Statistics 3. Evaluation and Validation 4. Regression 5. Classification 6. Clustering 7. Time Series and Anomaly Detection 8. Neural Networks and Deep Learning 9. Deploying and Distributing Analyses and Models 10. Algorithms/Techniques Related to Machine Learning

k-nearest neighbors

Moving on from logistic regression, let's try our first non-regression model, k-nearest neighbors (kNN). kNN is also a simple classification model, and it's one of the easiest model algorithms to grasp. It follows on from the basic premise that if I want to classify a record, I should consider other similar records.

kNN is implemented in multiple existing Go packages including github.com/sjwhitworth/golearn, github.com/rikonor/go-ann, github.com/akreal/knn, and github.com/cdipaolo/goml. We will be using the github.com/sjwhitworth/golearn implementation, which will serve as a great introduction to using github.com/sjwhitworth/golearn in general.

Overview of kNN

As mentioned, kNN operates on the...

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 $15.99/month. Cancel anytime}