Lýsing:
Algorithmic trading, once the exclusive domain of institutional players, is now open to small organizations and individual traders using online platforms. The tool of choice for many traders today is Python and its ecosystem of powerful packages. In this practical book, author Yves Hilpisch shows students, academics, and practitioners how to use Python in the fascinating field of algorithmic trading.
You'll learn several ways to apply Python to different aspects of algorithmic trading, such as backtesting trading strategies and interacting with online trading platforms. Some of the biggest buy- and sell-side institutions make heavy use of Python. By exploring options for systematically building and deploying automated algorithmic trading strategies, this book will help you level the playing field.
Set up a proper Python environment for algorithmic trading Learn how to retrieve financial data from public and proprietary data sources Explore vectorization for financial analytics with NumPy and pandas Master vectorized backtesting of different algorithmic trading strategies Generate market predictions by using machine learning and deep learning Tackle real-time processing of streaming data with socket programming tools Implement automated algorithmic trading strategies with the OANDA and FXCM trading platforms.
Annað
- Höfundur: Yves Hilpisch
- Útgáfa:1
- Útgáfudagur: 12-11-2020
- Engar takmarkanir á útprentun
- Engar takmarkanir afritun
- Format:ePub
- ISBN 13: 9781492053309
- Print ISBN: 9781492053354
- ISBN 10: 1492053309
Efnisyfirlit
- Preface
- Contents and Structure
- Who This Book Is For
- Conventions Used in This Book
- Using Code Examples
- O’Reilly Online Learning
- How to Contact Us
- Acknowledgments
- 1. Python and Algorithmic Trading
- Python for Finance
- Python Versus Pseudo-Code
- NumPy and Vectorization
- pandas and the DataFrame Class
- Algorithmic Trading
- Python for Algorithmic Trading
- Focus and Prerequisites
- Trading Strategies
- Simple Moving Averages
- Momentum
- Mean Reversion
- Machine and Deep Learning
- Conclusions
- References and Further Resources
- Python for Finance
- 2. Python Infrastructure
- Conda as a Package Manager
- Installing Miniconda
- Basic Operations with Conda
- Conda as a Virtual Environment Manager
- Using Docker Containers
- Docker Images and Containers
- Building a Ubuntu and Python Docker Image
- Using Cloud Instances
- RSA Public and Private Keys
- Jupyter Notebook Configuration File
- Installation Script for Python and Jupyter Lab
- Script to Orchestrate the Droplet Set Up
- Conclusions
- References and Further Resources
- Conda as a Package Manager
- 3. Working with Financial Data
- Reading Financial Data From Different Sources
- The Data Set
- Reading from a CSV File with Python
- Reading from a CSV File with pandas
- Exporting to Excel and JSON
- Reading from Excel and JSON
- Working with Open Data Sources
- Eikon Data API
- Retrieving Historical Structured Data
- Retrieving Historical Unstructured Data
- Storing Financial Data Efficiently
- Storing DataFrame Objects
- Using TsTables
- Storing Data with SQLite3
- Conclusions
- References and Further Resources
- Python Scripts
- Reading Financial Data From Different Sources
- 4. Mastering Vectorized Backtesting
- Making Use of Vectorization
- Vectorization with NumPy
- Vectorization with pandas
- Strategies Based on Simple Moving Averages
- Getting into the Basics
- Generalizing the Approach
- Strategies Based on Momentum
- Getting into the Basics
- Generalizing the Approach
- Strategies Based on Mean Reversion
- Getting into the Basics
- Generalizing the Approach
- Data Snooping and Overfitting
- Conclusions
- References and Further Resources
- Python Scripts
- SMA Backtesting Class
- Momentum Backtesting Class
- Mean Reversion Backtesting Class
- Making Use of Vectorization
- Using Linear Regression for Market Movement Prediction
- A Quick Review of Linear Regression
- The Basic Idea for Price Prediction
- Predicting Index Levels
- Predicting Future Returns
- Predicting Future Market Direction
- Vectorized Backtesting of Regression-Based Strategy
- Generalizing the Approach
- Using Machine Learning for Market Movement Prediction
- Linear Regression with scikit-learn
- A Simple Classification Problem
- Using Logistic Regression to Predict Market Direction
- Generalizing the Approach
- Using Deep Learning for Market Movement Prediction
- The Simple Classification Problem Revisited
- Using Deep Neural Networks to Predict Market Direction
- Adding Different Types of Features
- Conclusions
- References and Further Resources
- Python Scripts
- Linear Regression Backtesting Class
- Classification Algorithm Backtesting Class
- Backtesting Base Class
- Long-Only Backtesting Class
- Long-Short Backtesting Class
- Conclusions
- References and Further Resources
- Python Scripts
- Backtesting Base Class
- Long-Only Backtesting Class
- Long-Short Backtesting Class
- Running a Simple Tick Data Server
- Connecting a Simple Tick Data Client
- Signal Generation in Real Time
- Visualizing Streaming Data with Plotly
- The Basics
- Three Real-Time Streams
- Three Sub-Plots for Three Streams
- Streaming Data as Bars
- Conclusions
- References and Further Resources
- Python Scripts
- Sample Tick Data Server
- Tick Data Client
- Momentum Online Algorithm
- Sample Data Server for Bar Plot
- Setting Up an Account
- The Oanda API
- Retrieving Historical Data
- Looking Up Instruments Available for Trading
- Backtesting a Momentum Strategy on Minute Bars
- Factoring In Leverage and Margin
- Working with Streaming Data
- Placing Market Orders
- Implementing Trading Strategies in Real Time
- Retrieving Account Information
- Conclusions
- References and Further Resources
- Python Script
- Getting Started
- Retrieving Data
- Retrieving Tick Data
- Retrieving Candles Data
- Working with the API
- Retrieving Historical Data
- Retrieving Streaming Data
- Placing Orders
- Account Information
- Conclusions
- References and Further Resources
- Capital Management
- Kelly Criterion in Binomial Setting
- Kelly Criterion for Stocks and Indices
- ML-Based Trading Strategy
- Vectorized Backtesting
- Optimal Leverage
- Risk Analysis
- Persisting the Model Object
- Online Algorithm
- Infrastructure and Deployment
- Logging and Monitoring
- Visual Step-by-Step Overview
- Configuring Oanda Account
- Setting Up the Hardware
- Setting Up the Python Environment
- Uploading the Code
- Running the Code
- Real-Time Monitoring
- Conclusions
- References and Further Resources
- Python Script
- Automated Trading Strategy
- Strategy Monitoring
- Python Basics
- Data Types
- Data Structures
- Control Structures
- Python Idioms
- NumPy
- Regular ndarray Object
- Vectorized Operations
- Boolean Operations
- ndarray Methods and NumPy Functions
- ndarray Creation
- Random Numbers
- matplotlib
- pandas
- DataFrame Class
- Numerical Operations
- Data Selection
- Boolean Operations
- Plotting with pandas
- Input-Output Operations
- Case Study
- Conclusions
- Further Resources
UM RAFBÆKUR Á HEIMKAUP.IS
Bókahillan þín er þitt svæði og þar eru bækurnar þínar geymdar. Þú kemst í bókahilluna þína hvar og hvenær sem er í tölvu eða snjalltæki. Einfalt og þægilegt!Rafbók til eignar
Rafbók til eignar þarf að hlaða niður á þau tæki sem þú vilt nota innan eins árs frá því bókin er keypt.
Þú kemst í bækurnar hvar sem er
Þú getur nálgast allar raf(skóla)bækurnar þínar á einu augabragði, hvar og hvenær sem er í bókahillunni þinni. Engin taska, enginn kyndill og ekkert vesen (hvað þá yfirvigt).
Auðvelt að fletta og leita
Þú getur flakkað milli síðna og kafla eins og þér hentar best og farið beint í ákveðna kafla úr efnisyfirlitinu. Í leitinni finnur þú orð, kafla eða síður í einum smelli.
Glósur og yfirstrikanir
Þú getur auðkennt textabrot með mismunandi litum og skrifað glósur að vild í rafbókina. Þú getur jafnvel séð glósur og yfirstrikanir hjá bekkjarsystkinum og kennara ef þeir leyfa það. Allt á einum stað.
Hvað viltu sjá? / Þú ræður hvernig síðan lítur út
Þú lagar síðuna að þínum þörfum. Stækkaðu eða minnkaðu myndir og texta með multi-level zoom til að sjá síðuna eins og þér hentar best í þínu námi.
Fleiri góðir kostir
- Þú getur prentað síður úr bókinni (innan þeirra marka sem útgefandinn setur)
- Möguleiki á tengingu við annað stafrænt og gagnvirkt efni, svo sem myndbönd eða spurningar úr efninu
- Auðvelt að afrita og líma efni/texta fyrir t.d. heimaverkefni eða ritgerðir
- Styður tækni sem hjálpar nemendum með sjón- eða heyrnarskerðingu
- Gerð : 208
- Höfundur : 16346
- Útgáfuár : 2020
- Leyfi : 379