Hands-On Financial Trading with Python: A practical guide to using Zipline and other Python libraries for backtesting trading strategies - Original PDF

دانلود کتاب Hands-On Financial Trading with Python: A practical guide to using Zipline and other Python libraries for backtesting trading strategies - Original PDF

Author: Jiri Pik, Sourav Ghosh

0 (0)

توضیحات کتاب :

Discover how to build and backtest algorithmic trading strategies with Zipline Key Features Get to grips with market data and stock analysis and visualize data to gain quality insights Find out how to systematically approach quantitative research and strategy generation/backtesting in algorithmic trading Learn how to navigate the different features in Python's data analysis libraries Book Description Algorithmic trading helps you stay ahead of the markets by devising strategies in quantitative analysis to gain profits and cut losses. The book starts by introducing you to algorithmic trading and explaining why Python is the best platform for developing trading strategies. You'll then cover quantitative analysis using Python, and learn how to build algorithmic trading strategies with Zipline using various market data sources. Using Zipline as the backtesting library allows access to complimentary US historical daily market data until 2018. As you advance, you will gain an in-depth understanding of Python libraries such as NumPy and pandas for analyzing financial datasets, and explore Matplotlib, statsmodels, and scikit-learn libraries for advanced analytics. You'll also focus on time series forecasting, covering pmdarima and Facebook Prophet. By the end of this trading book, you will be able to build predictive trading signals, adopt basic and advanced algorithmic trading strategies, and perform portfolio optimization. What you will learn Discover how quantitative analysis works by covering financial statistics and ARIMA Use core Python libraries to perform quantitative research and strategy development using real datasets Understand how to access financial and economic data in Python Implement effective data visualization with Matplotlib Apply scientific computing and data visualization with popular Python libraries Build and deploy backtesting algorithmic trading strategies Who this book is for This book is for data analysts and financial traders who want to explore how to design algorithmic trading strategies using Python's core libraries. If you are looking for a practical guide to backtesting algorithmic trading strategies and building your own strategies, then this book is for you. Beginner-level working knowledge of Python programming and statistics will be helpful. Table of Contents Introduction to algorithmic trading Exploratory Data Analysis in Python High-speed Scientific Computing using NumPy Data Manipulation and Analysis with Pandas Data Visualization using Matplotlib Statistical Estimation, Inference, and Prediction Financial Market Data Access in Python Introduction to Zipline and PyFolio Fundamental algorithmic trading strategies

سرچ در وردکت | سرچ در گودریدز | سرچ در اب بوکز | سرچ در آمازون | سرچ در گوگل بوک

1,182 بازدید 0 خرید

ضمانت بازگشت

ضمانت بازگشت

فایل های تست شده

فایل های تست شده

پرداخت آنلاین

پرداخت آنلاین

تضمین کیفیت

تضمین کیفیت

دانلود فوری

دانلود فوری

Walking through the evolution of algorithmic trading The concept of trading one possession for another has been around since the beginning of time. In its earliest form, trading was useful for exchanging a less desirable possession for a more desirable possession. Eventually, with the passage of time, trading has evolved into participants trying to find a way to buy and hold trading instruments (that is, products) at prices perceived as lower than fair value in the hopes of being able to sell them in the future at a price higher than the purchase price. This buy-low-and-sell-high principle serves as the basis for all profitable trading to date; of course, how to achieve this is where the complexity and competition lies. Markets are driven by the fundamental economic forces of supply and demand. As demand increases without a commensurate increase in supply, or supply decreases without a decrease in demand, a commodity becomes scarce and increases in value (that is, its market price). Conversely, if demand drops without a decrease in supply, or supply increases without an increase in demand, a commodity becomes more easily available and less valuable (a lower market price). Therefore, the market price of a commodity should reflect the equilibrium price based on available supply (sellers) and available demand (buyers)

چکیده فارسی

 

پیمایی در سیر تکامل معاملات الگوریتمی مفهوم معامله یک دارایی با دیگری از ابتدا وجود داشته است. در اولین شکل خود، تجارت برای مبادله دارایی کمتر مطلوب با دارایی مطلوب تر مفید بود. در نهایت، با گذشت زمان، معاملات به شرکت‌کنندگانی تبدیل شد که تلاش می‌کنند راهی برای خرید و نگهداری ابزارهای معاملاتی (یعنی محصولات) با قیمت‌هایی که کمتر از ارزش منصفانه در نظر گرفته می‌شوند، بیابند، به امید اینکه بتوانند در آینده آنها را بفروشند. با قیمتی بالاتر از قیمت خرید این اصل خرید پایین و فروش بالا به عنوان مبنایی برای تمام معاملات سودآور تا به امروز عمل می کند. البته، چگونگی دستیابی به این موضوع جایی است که پیچیدگی و رقابت نهفته است. بازارها توسط نیروهای اقتصادی اساسی عرضه و تقاضا هدایت می شوند. همانطور که تقاضا بدون افزایش متناسب در عرضه افزایش می یابد، یا عرضه بدون کاهش تقاضا کاهش می یابد، یک کالا کمیاب می شود و ارزش آن (یعنی قیمت بازار آن) افزایش می یابد. برعکس، اگر تقاضا بدون کاهش عرضه کاهش یابد، یا عرضه بدون افزایش تقاضا افزایش یابد، کالایی راحت‌تر در دسترس و کم ارزش‌تر می‌شود (قیمت بازار پایین‌تر). بنابراین، قیمت بازار یک کالا باید منعکس کننده قیمت تعادلی بر اساس عرضه موجود (فروشندگان) و تقاضای موجود (خریداران) باشد

 

ادامه ...

Author(s): Jiri Pik, Sourav Ghosh

Publisher: Packt Publishing, Year: 2021

ISBN: 1838982884,9781838982881

ادامه ...

Table of Contents Preface Section 1: Introduction to Algorithmic Trading 1 Introduction to Algorithmic Trading Walking through the evolution of algorithmic trading 4 Understanding financial asset classes 6 Going through the modern electronic trading exchange 7 Order types 7 Limit order books 8 The exchange matching engine 9 Understanding the components of an algorithmic trading system 9 The core infrastructure of an algorithmic trading system 10 The quantitative infrastructure of an algorithmic trading system 11 Summary 16 Section 2: In-Depth Look at Python Libraries for the Analysis of Financial Datasets 2 Exploratory Data Analysis in Python Technical requirements 19 Introduction to EDA 20 Steps in EDA 20 Revelation of the identity of A, B, and C and EDA's conclusions 41 Special Python libraries for EDA 42 Summary 44 ii Table of Contents 3 High-Speed Scientific Computing Using NumPy Technical requirements 46 Introduction to NumPy 46 Creating NumPy ndarrays 46 Creating 1D ndarrays 46 Creating 2D ndarrays 47 Creating any-dimension ndarrays 47 Creating an ndarray with np.zeros(...) 48 Creating an ndarray with np.ones(...) 48 Creating an ndarray with np.identity(...) 49 Creating an ndarray with np.arange(...) 49 Creating an ndarray with np.random. randn(...) 49 Data types used with NumPy ndarrays 50 Creating a numpy.float64 array 50 Creating a numpy.bool array 50 ndarrays' dtype attribute 51 Converting underlying data types of ndarray with numpy.ndarrays.astype(...) 51 Indexing of ndarrays 51 Direct access to an ndarray's element 52 ndarray slicing 53 Boolean indexing 56 Indexing with arrays 58 Basic ndarray operations 59 Scalar multiplication with an ndarray 59 Linear combinations of ndarrays 59 Exponentiation of ndarrays 59 Addition of an ndarray with a scalar 60 Transposing a matrix 60 Changing the layout of an ndarray 60 Finding the minimum value in an ndarray 61 Calculating the absolute value 61 Calculating the mean of an ndarray 62 Finding the index of the maximum value in an ndarray 62 Calculating the cumulative sum of elements of an ndarray 63 Finding NaNs in an ndarray 63 Finding the truth values of x1>x2 of two ndarrays 64 any and all Boolean operations on ndarrays 65 Sorting ndarrays 66 Searching within ndarrays 68 File operations on ndarrays 69 File operations with text files 69 File operations with binary files 70 Summary 71 4 Data Manipulation and Analysis with pandas Introducing pandas Series, pandas DataFrames, and pandas Indexes 74 pandas.Series 74 pandas.DataFrame 76 pandas.Index 79 Learning essential pandas. DataFrame operations 80 Table of Contents iii Indexing, selection, and filtering of DataFrames 80 Dropping rows and columns from a DataFrame 82 Sorting values and ranking the values' order within a DataFrame 84 Arithmetic operations on DataFrames 86 Merging and combining multiple DataFrames into a single DataFrame 88 Hierarchical indexing 91 Grouping operations in DataFrames 94 Transforming values in DataFrames' axis indices 97 Handling missing data in DataFrames 98 The transformation of DataFrames with functions and mappings 101 Discretization/bucketing of DataFrame values 102 Permuting and sampling DataFrame values to generate new DataFrames 104 Exploring file operations with pandas.DataFrames 106 CSV files 106 JSON files 108 Summary 109 5 Data Visualization Using Matplotlib Technical requirements 112 Creating figures and subplots 112 Defining figures' subplots 112 Plotting in subplots 113 Enriching plots with colors, markers, and line styles 116 Enriching axes with ticks, labels, and legends 118 Enriching data points with annotations 120 Saving plots to files 123 Charting a pandas DataFrame with Matplotlib 124 Creating line plots of a DataFrame column 125 Creating bar plots of a DataFrame column 126 Creating histogram and density plots of a DataFrame column 128 Creating scatter plots of two DataFrame columns 130 Plotting time series data 133 Summary 144 6 Statistical Estimation, Inference, and Prediction Technical requirements 146 Introduction to statsmodels 146 Normal distribution test with Q-Q plots 146 Time series modeling with statsmodels 148 ETS analysis of a time series 149 Augmented Dickey-Fuller test for stationarity of a time series 157 Autocorrelation and partial autocorrelation of a time series 159 ARIMA time series model 161 iv Table of Contents Using a SARIMAX time series model with pmdarima 166 Time series forecasting with Facebook's Prophet library 171 Introduction to scikit-learn regression and classification 174 Generating the dataset 174 Running RidgeCV regression on the dataset 178 Running a classification method on the dataset 182 Summary 186 Section 3: Algorithmic Trading in Python 7 Financial Market Data Access in Python Exploring the yahoofinancials Python library 190 Single-ticker retrieval 191 Multiple-tickers retrieval 198 Exploring the pandas_ datareader Python library 201 Access to Yahoo Finance 202 Access to EconDB 203 Access to the Federal Reserve Bank of St Louis' FRED 204 Caching queries 205 Exploring the Quandl data source 206 Exploring the IEX Cloud data source 207 Exploring the MarketStack data source 209 Summary 211 8 Introduction to Zipline and PyFolio Introduction to Zipline and PyFolio 214 Installing Zipline and PyFolio 214 Installing Zipline 214 Installing PyFolio 215 Importing market data into a Zipline/PyFolio backtesting system 215 Importing data from the historical Quandl bundle 215 Importing data from the CSV files bundle 218 Importing data from custom bundles 219 Structuring Zipline/PyFolio backtesting modules 229 Trading happens every day 230 Trading happens on a custom schedule 231 Reviewing the key Zipline API reference 233 Table of Contents v Types of orders 233 Commission models 234 Slippage models 234 Running Zipline backtesting from the command line 235 Introduction to risk management with PyFolio 236 Market volatility, PnL variance, and PnL standard deviation 239 Trade-level Sharpe ratio 240 Maximum drawdown 242 Summary 244 9 Fundamental Algorithmic Trading Strategies What is an algorithmic trading strategy? 246 Learning momentum-based/ trend-following strategies 248 Rolling window mean strategy 248 Simple moving averages strategy 254 Exponentially weighted moving averages strategy 259 RSI strategy 265 MACD crossover strategy 270 RSI and MACD strategies 276 Triple exponential average strategy 282 Williams R% strategy 287 Learning mean-reversion strategies 292 Bollinger band strategy 292 Pairs trading strategy 298 Learning mathematical model-based strategies 305 Minimization of the portfolio volatility strategy with monthly trading 305 Maximum Sharpe ratio strategy with monthly trading 312 Learning time series prediction-based strategies 317 SARIMAX strategy 318 Prophet strategy 323 Summary 328 Appendix A How to Setup a Python Environment Technical requirements 329 Initial setup 329 Downloading the complimentary Quandl data bundle 332 Other Books You May Enjoy Index

ادامه ...
برای ارسال نظر لطفا وارد شوید یا ثبت نام کنید
ادامه ...
پشتیبانی محصول

۱- در صورت داشتن هرگونه مشکلی در پرداخت، لطفا با پشتیبانی تلگرام در ارتباط باشید.

۲- برای خرید محصولات لطفا به شماره محصول و عنوان دقت کنید.

۳- شما می توانید فایلها را روی نرم افزارهای مختلف اجرا کنید(هیچگونه کد یا قفلی روی فایلها وجود ندارد).

۴- بعد از خرید، محصول مورد نظر از صفحه محصول قابل دانلود خواهد بود همچنین به ایمیل شما ارسال می شود.

۵- در صورت وجود هر مشکلی در فرایند خرید با تماس بگیرید.