Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Machine Learning for Finance

You're reading from   Machine Learning for Finance Principles and practice for financial insiders

Arrow left icon
Product type Paperback
Published in May 2019
Publisher Packt
ISBN-13 9781789136364
Length 456 pages
Edition 1st Edition
Languages
Arrow right icon
Authors (2):
Arrow left icon
Jannes Klaas Jannes Klaas
Author Profile Icon Jannes Klaas
Jannes Klaas
James Le James Le
Author Profile Icon James Le
James Le
Arrow right icon
View More author details
Toc

Table of Contents (15) Chapters Close

Machine Learning for Finance
Contributors
Preface
Other Books You May Enjoy
1. Neural Networks and Gradient-Based Optimization 2. Applying Machine Learning to Structured Data FREE CHAPTER 3. Utilizing Computer Vision 4. Understanding Time Series 5. Parsing Textual Data with Natural Language Processing 6. Using Generative Models 7. Reinforcement Learning for Financial Markets 8. Privacy, Debugging, and Launching Your Products 9. Fighting Bias 10. Bayesian Inference and Probabilistic Programming Index

Summary

And that's it! We've learned how neural networks work. Throughout the rest of this book, we'll look at how to build more complex neural networks that can approximate more complex functions.

As it turns out, there are a few tweaks to make to the basic structure for it to work well on specific tasks, such as image recognition. The basic ideas introduced in this chapter, however, stay the same:

  • Neural networks function as approximators
  • We gauge how well our approximated function, Summary, performs through a loss function
  • Parameters of the model are optimized by updating them in the opposite direction of the derivative of the loss function with respect to the parameter
  • The derivatives are calculated backward through the model using the chain rule in a process called backpropagation

The key takeaway from this chapter is that while we are looking for function f, we can try and find it by optimizing a function to perform like f on a dataset. A subtle but important distinction is that we do not know whether Summary works like f at all. An often-cited example is a military project that tried to use deep learning to spot tanks within images. The model trained well on the dataset, but once the Pentagon wanted to try out their new tank spotting device, it failed miserably.

In the tank example, it took the Pentagon a while to figure out that in the dataset they used to develop the model, all the pictures of the tanks were taken on a cloudy day and pictures without a tank where taken on a sunny day. Instead of learning to spot tanks, the model had learned to spot grey skies instead.

This is just one example of how your model might work very differently to how you think, or even plan for it to do. Flawed data might seriously throw your model off track, sometimes without you even noticing. However, for every failure, there are plenty of success stories in deep learning. It is one of the high-impact technologies that will reshape the face of finance.

In the next chapter, we will get our hands dirty by jumping in and working with a common type of data in finance, structured tabular data. More specifically, we will tackle the problem of fraud, a problem that many financial institutions sadly have to deal with and for which modern machine learning is a handy tool. We will learn about preparing data and making predictions using Keras, scikit-learn, and XGBoost.

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