Learning Track: Algorithmic Trading for Beginners
₹27859/-₹32775/-
76% OFF
+ Additional 15% OFF
- Live Trading
- Learning Track
- Prerequisites
- Syllabus
- About author
- Testimonials
- Faqs
Automated Trading for Beginners

Skills Covered
Strategy Paradigms
- Pairs Trading
- Post Earnings Announcement Drift
- Scalping
- ARIMA
- Turn-of-Month Strategy
Math & Core Concepts
- Correlation, Cointegration, Stationarity
- Simple, Cumulative & Log Returns
- ADF test
- Half-Life & Linear Regression
Python Libraries
- Statsmodels
- Adfuller
- NumPy, Pandas
- Matplotlib
- TA - Lib & sqlalchemy

learning track 1
Algorithmic Trading for Beginners
Full Learning Track
These courses are specially curated to help you with end-to-end learning of the subject.
Course Features
- Community
Faculty Support on Community
- Interactive Coding Exercises
Interactive Coding Practice
- Capstone Project
Capstone Project using Real Market Data
- Trade & Learn Together
Trade and Learn Together
- Get Certified
Get Certified
Prerequisites
You might have never coded before or never created any trading strategy. The learning curve could be steep if you are a beginner in both these skills. However, you can practise regularly on the hands-on learning exercises given in the course and build the required skills gradually. As a prerequisite only need to know the basic terms and fundamental concepts of the stock market. To acquire this knowledge, you can do the free course on “Stock Market Basics” at Quantra, an ideal starting point for an algo trading beginner.
Syllabus
- IntroductionThis section introduces the topic of Algorithmic Trading. You will be guided through the detailed course structure and the various concepts covered in the course. You will also explore various features that are available to you on Quantra.Introduction3m 59sCourse Structure2m 36sCourse Structure Flow Diagram10mQuantra Features and Guidance3m 48s
What is Algorithmic Trading?
This section introduces the topic of Algorithmic Trading and states important concepts like Direct Market Access(DMA), advantages of colocation, HFT, and quantitative trading.What is Algorithmic Trading?1m 18sAlgorithmic Trading System Fail2mQuantitative Analysis2mDirect Market Access3m 44sWhat is DMA?2mWhat is High-frequency trading?3m 4sCharacteristics of HFT2mWhy Algorithmic Trading?
This section aims to help you understand the benefits of Algorithmic Trading and why it is preferred over traditional trading techniques. It also explains the concept of backtesting and how it can help in optimising your algorithmic trading strategies.Why Go Algo (part 1)1m 44sKnow About Algorithmic Trading2mWhat is Colocation?2mAdvantages of Colocation2mLow Latency in Algorithmic Trading2mWhy Go Algo (part 2)2m 43sResearch Backtesting2mKnow 'In Sample Backtesting'2mUnderstanding Backtesting2mWhy Go Algo (part 3)1m 17sHow to Start Algorithmic Trading1m 46sAdvantages of Algorithmic Trading2mTest on the Definition and Need of Algorithmic Trading10m- Available Platforms & LanguagesThis section discusses some of the platforms and programming languages available to trade algorithmically.Available Platforms & Languages2m 21sProgramming Language for Algo Trading2mCost of Using Programming Language2m
- Strategy ParadigmsThis section explains some algorithmic trading strategies. It includes concepts like market making, momentum-based trading strategies, trend-following strategies, arbitrage strategies, and Machine Learning used in algorithmic trading strategies.Types of Algorithmic Trading Strategies3m 7sMarket Making Strategy3m 24sKnow How Market Makers Profit2mCharacteristics of Illiquid Securities2mBenefit of Market Making2mInventory Risk2mAdverse Selection Spread2mStatistical Arbitrage1m 27sArbitrage Trading Strategies2mPair Trading Follows2mWhen is Pair Trading Profitable?2mMomentum Based Strategies3m 13sUsing Momentum Based Strategies2mUsing Trend Following Strategies2mMachine Readable News & ML3m 13sExamples of Scheduled News Event2mHow Machine Learning Models Work?2mTest on Strategy Paradigms10m
- Algorithmic Trading PlatformThis section explains the various components of the system architecture of an algorithmic trading platform like Market Data Adapter (MDA), Complex Events Processing engine (CEP), and Order Management/routing System (OMS).Algorithmic Trading Platform10mHow Market Data Adapter Works?2mWhy Use CEP Engine?2mWhat is OMS?2mCore of Algorithmic Trading System2m
- Introduction to PythonThis section will help you update your knowledge of Python with simple exercises on implementing functions, and manipulating dataframes using Numpy and Pandas libraries. The Quantra environment ensures that you don’t have to install anything for the Jupyter notebooks to function.Uninterrupted Learning Journey with Quantra2mNeed for Python3m 4sPreference for Python2mFunctionality of Python2mHow to Use Jupyter Notebook?2m 5sPrint Statement5mMy First Jupyter Notebook10mGetting Started with Interactive Exercises5mOperations and Functions in Python10mDivide Two Numbers5mPandas Dataframe2m 7sFunction Call5mDataFrame Axis Label2mDataFrame and Basic Functionality10mDataFrame Syntax2mDropping/Deleting Columns2mCreate Pandas DataFrame5mDataFrame Indexing2mPrint Columns2mAccess Elements of a DataFrame5mAdd New Column to a DataFrame5mSet Column as Index5mAdd Values of a Column5mAdditional Reading10m
- Financial Market Data and VisualisationAn important component of a successful strategy is the data set used. In this section, you will learn how to import the correct data from various web resources, so that you can work on your own unique strategy.Importing Data1m 39sCorrect Syntax for Importing Stock Data2mImporting Time Series Data10mDownload of Historical Data5mData Visualisation10mPlot Line Graph5mPlot Bar Graph5mAdditional Reading10mFrequently Asked Questions10m
Moving Average Crossover Strategy
Learn how to use moving average crossover strategy in Python. This unit covers the calculation of strategy returns as well as generation of buy and sell signals.Moving Average Crossover Strategy3m 24sWhy Use Short Term Average2mCalculate Rolling Average2mBuy or Sell?2mWhat is the Sharpe ratio?2mMoving Average Crossover Strategy10mPrint the Message5mImport Module5mRead Data File5mCalculate Daily Change5mCreate a New Column With NaN2mCalculate Short Term Moving Average5mCalculate Long Term Moving Average5mGenerate Buy and Sell Signals5mCalculate Strategy Returns5m- Live Trading on BlueshiftThis section will walk you through the steps involved in taking your trading strategy live. You will learn about backtesting and live trading platform, Blueshift. You will learn about code structure, various functions used to create a strategy and finally, paper or live trade on Blueshift.Section Overview2m 19sLive Trading Overview2m 41sVectorised vs Event Driven2mProcess in Live Trading2mReal-Time Data Source2mBlueshift Code Structure2m 57sImportant API Methods10mSchedule Strategy Logic2mFetch Historical Data2mPlace Orders2mBacktest and Live Trade on Blueshift4m 5sAdditional Reading10mBlueshift Data FAQs10m
- Live Trading TemplateBlueshift Live Trading TemplatePaper/Live Trading Moving Average Crossover10mFAQs for Live Trading on Blueshift10m
- Regulations & Compliance (Optional Section)This section takes you through the regulations and compliance requirements like audit requirements, control parameters, and more.Regulations & Compliance10mAdditional Reading10m
- Run Codes Locally on Your MachineLearn to install the Python environment in your local machine.Python Installation Overview1m 59sFlow Diagram10mInstall Anaconda on Windows10mInstall Anaconda on Mac10mKnow your Current Environment2mTroubleshooting Anaconda Installation Problems10mCreating a Python Environment10mChanging Environments2mQuantra Environment2mTroubleshooting Tips For Setting Up Environment10mHow to Run Files in Downloadable Section?10mTroubleshooting For Running Files in Downloadable Section10m
- SummaryThis consists of the summary of the entire course and downloadable e-book on ‘Getting Started With Algorithmic Trading’ for reference.Setting Up a Trading Desk FAQs10mDownloadable E-book10mSummary2m 51sPython Codes and Data2m
- WelcomeThis section introduces the topic and explains the importance of Python.Introduction2m 40sIf Algo, Then How Does Python Contribute?6m 27sQuantra Features and Guidance3m 48sFAQ2m
- Hello PythonThis familiarises you with the basic components of Python like variables references, operators, modules, packages, and libraries.Python Environment2m 34sVariables, Object References and Operators3m 36sWhen X = Y, Then What?2mWhen X != Y, Then What?2mHow to Use Jupyter Notebook?2m 5sMy First Python Code10mPractice Print Statement5mLearn Modules, Packages and Libraries3m 11sFile With .py Extension2mImport Python Modules10mModules, Packages & Libraries2mImporting Module5mInstall Packages in Python10mError if the Package is Not Installed2mSyntax to Install a Package2mWhich Version of the Package is Installed?2mSyntax to Install a Version?2mTest on Python Modules16m
- ExpressionsIn this section, you will learn about an important concept of 'Time Value of Money', and the use of expressions in Python.Introduction to Time Value of Money1m 51sCalculate the Future Value2mCalculate the Present Value2mLearn Compounding in Time Value of Money2m 6sCompounding With Monthly Coupons2mCompounding With Quarterly Coupons2mPDF: TVM Applications (Optional Read)10mUse of Expressions10mPrint Future Value5mPrint Calculating Present Value5m
- Python Data StructuresThis section focuses on different Python data structures like lists, dictionaries, stacks, queues, graphs, trees, tuples and sets.What Are Lists?4m 6sSyntax for Lists2mProperties of List2mLearn to Create Lists10mCreate Lists on Your Own5mPrint pop() From Lists5mWhat Are Stacks, Queues, Graphs & Trees10mStacks & Queues2mWhat Are Dictionaries?1m 55sAccess Dictionaries2mKeys in Dictionaries2mLearn to Create and Print Dictionaries10mCreate Dictionaries5mPractice Printing Keys5mWhat Are Tuples and Sets?2m 25sWhich is Valid for Data Structures?2mTuples2mLearn to Create Tuples and Sets10mConstruct Tuple5mPrint Set Union function5mTest on Expressions and Python Data Structures14m
- Importing Data and Data VisualisationThis section demonstrates how to import and visualise financial data using Python.What is Time Series Data?3m 19sTime Series: A Collection of Observations2mCharacteristics of Longitudinal & Panel Data2mHow to Import Time series data?3m 6sFind: True/False for DataFrame2mCorrect Syntax for a DataFrame2mImport Data from Web Sources10mDownload of Historical Data5mRead Data from CSV Files10mPractice read_csv()5mHow to Plot Market Data?3m 48sGiving Title to the Graph2mFunction to Visualise the Graph2mData Visualization10mCreate 2D Plot5mPlot the Grid5m3D Plotting10mWhat are Candlesticks?4m 14sAssessment on Green Candlesticks2mAdvantage of Candlesticks2mCandlesticks (Optional Read)10mTest on Importing Data and Data Visualisation14m
- FunctionsIn this section, you will learn what Python functions are, how to define functions, what Lambda functions are and how to use them.What Are Functions?4m 30sAssessment: What Are Functions?2mSyntax to Define a Function2mFunctions10mPrint Using Function5mCall the Function5mLambda10mCreate Sum of Variables with Lamba5mMultiplication of Variables With Lambda5m
- NumpyThis section shows how you can use the NumPy library to manipulate arrays by slicing, indexing, vectorization and broadcasting.What Are NumPy Arrays?3m 51sAssessment on NumPy2mPut Syntax for Array Constructor2mIntroduction to Arrays10mUse Numpy.arange ()2mCreate Array With Linspace5mCreate 2D Array5mIndexing & Slicing Arrays10mIndexing 1D Arrays2mIndexing 2D Arrays2mSlicing 1D Arrays2mSlicing 2D Arrays2mPractice Indexing5mPractice Slicing5mVectorization & Broadcasting in Arrays10mScalar Vectorization2mArray Comparison2mPractice Using == Operator5mPractice New Axis5m
- PandasThis section illustrates how to use the Pandas library for the manipulation of DataFrames.Pandas and Data Manipulation4m 26sDropping/Deleting Columns2mDataframe Indexing2mIntroduction to Series10mAssessment on Series.apply()2mPractice Creating Series5mApply Method to a Series5mDataFrame & Basic Functionality10mPrinting Columns2mPractice Using DataFrame.head()5mCreate DataFrame5mDescriptive Statistical Function10mDataframe Manipulation2mPrint Using mean()5mPractice corr()5mIndexing & Missing Values10mloc()2miloc()5mGrouping & Reshaping10mGroupby Function5m
- Conditional Statements and LoopsIn this section, you will learn how to use conditional statements and loops in Python.What Are Conditional Statements and Loops?4m 18sAssessment on 'if' Conditional Statement2mWhat Do You Know About 'for loop'?2mIntroduction to Conditional Statements10mIf Conditional Statement5mIntroduction to Loops10mFor Loop5mGetting Out of 'for Loop'5mTest on Libraries, Functions, and Loops16m
Buy and Hold Strategy
In this section, you will learn to create a buy and hold strategy in Python.Buy and Hold Strategy10mFrequently Asked Questions10m- Live Trading on BlueshiftThis section will walk you through the steps involved in taking your trading strategy live. You will learn about backtesting and live trading platform, Blueshift. You will learn about code structure, various functions used to create a strategy and finally, paper or live trade on Blueshift.Uninterrupted Learning Journey with Quantra2mSection Overview2m 19sLive Trading Overview2m 41sVectorised vs Event Driven2mProcess in Live Trading2mReal-Time Data Source2mBlueshift Code Structure2m 57sImportant API Methods10mSchedule Strategy Logic2mFetch Historical Data2mPlace Orders2mBacktest and Live Trade on Blueshift4m 5sAdditional Reading10mBlueshift Data FAQs10m
- Live Trading TemplateBlueshift Live Trading TemplatePaper/Live Trading Buy and Hold Strategy10mSharpe Ratio5mStrategy Returns5mMaximum Drawdown5mEnding Capital5mNext Step5mPaper Trading5mInvestment Style5mRebalancing Function5mFAQs for Live Trading on Blueshift10m
- Run Codes Locally on Your MachineLearn to install the Python environment in your local machine.Python Installation Overview1m 59sFlow Diagram10mInstall Anaconda on Windows10mInstall Anaconda on Mac10mKnow your Current Environment2mTroubleshooting Anaconda Installation Problems10mCreating a Python Environment10mChanging Environments2mQuantra Environment2mTroubleshooting Tips For Setting Up Environment10mHow to Run Files in Downloadable Section?10mTroubleshooting For Running Files in Downloadable Section10m
- Course SummaryCourse Summary and Next Steps10mPython Code and Data2m
- Course IntroductionThe first step in creating a trading strategy is to retrieve data. While there are a plethora of resources available for free or paid, it makes sense to use a trusted data provider. In this section, you will understand the importance of data and also acquaint yourself with the course structure.Introduction to the Course2m 16sCourse Structure2m 14sCourse Structure Flow Diagram10m
- Equity Price DataStock price analysis is one of the most important tools to make an informed decision while trading. In this section, you will learn how to fetch the various stock price data. You will learn how to download the adjusted and unadjusted price data of different frequencies such as 15 minutes, 1 hour and 1 day.Stock Daily Price Data5mDownload of Historical Data5mData Adjusted for Corporate Actions2mStock Index Data5mList of Tickers in S&P5005mGetting Close Data5mMinute Price Data and Resampling Techniques5mResample Data2mAggregate function5mData from Different Geographies10mDownload Data from Yahoo! Finance10mAdditional Reading10m
- Forex Price DataIn this section, you will learn to obtain historical forex. The data is visualised in the Jupyter notebook.Forex Price Data10mMinute Price Data for AUD/USD5mAdditional Reading10m
- Crypto DataIn this section, you will learn to obtain historical data for cryptocurrency assets. The data is visualised in the Jupyter notebook.Cryptocurrency Data5mAdditional Reading10m
- Futures DataIn this section, you will learn how to fetch data for continuous futures contracts and their limitations. You will learn about the proportional adjustment method to stitch and create a continuous futures contract.Futures Data5mFutures Continuations10mAdditional Reading10m
- Options DataOptions are derivative contracts that derive their value from the underlying securities, such as stocks. In this section, you will learn to fetch options chain data for the US equities market from Yahoo Finance.Options Chain Data From Yahoo! Finance10mPut Option Premium Vs Strike Price2mAdditional Reading10mGetting Options Data for Different Geographies2m
- Stock Fundamental DataIn this section, you will learn how to fetch fundamental data like income statements, balance sheets and cash flow statements. And calculate fundamental ratios such as current ratio, return on equity and debt to equity ratio. You will then learn to fetch earnings calendar, analyst recommendations and institutional holders.Fundamental Data10mRatios from Fundamental Data10mOther Company Data10mAdditional Reading10m
- Macro DataMacro data gives a bigger picture of how a country’s economy is performing. This section will take you through various sources such as FRED and yfinance to fetch these data. You will fetch the macro data such as GDP, Inflation and Rates.Macro Data10mGross Domestic Product of US5mUS Treasury Rate Chart2mAdditional Reading10m
- News DataInitially, traders and investors would go through the financial section of the newspapers and depending on the news, buy or sell their favourite assets. As the world moved online, consumption of news moved too. News is disseminated instantaneously and so are trading decisions. This section will help you fetch and aggregate the news from major digital platforms so that you can make your trading decisions faster.Fetch News Headlines5mAdditional Reading10m
- Data Quality Checks and Data CleaningThis section covers the data quality checks on the market data and methods used for data cleaning. This section also includes an assessment test on concepts covered in this course so far to test your learning.Basic Data Quality Checks and Data Cleaning10mCount of Null Values5mDrop the Missing Value5mCount of Duplicate Values5mINFO Method2mOutliers2mAdditional Reading10mTest on Getting Market Data12m
- Run Codes Locally on Your MachineLearn to install the Python environment in your local machine.Uninterrupted Learning Journey with Quantra2mPython Installation Overview1m 59sFlow Diagram10mInstall Anaconda on Windows10mInstall Anaconda on Mac10mKnow your Current Environment2mTroubleshooting Anaconda Installation Problems10mCreating a Python Environment10mChanging Environments2mQuantra Environment2mTroubleshooting Tips For Setting Up Environment10mHow to Run Files in Downloadable Section?10mTroubleshooting For Running Files in Downloadable Section10m
- ResourcesIn this section, you will be able to download all the strategy notebooks as a zip file. You can use these notebooks and modify their contents according to your needs.Course Summary and Next Steps10mPython Codes and Data2m
- Introduction to the CourseThis section introduces the day trading and explains the advantages of it. Day trading means you enter and exit the trade on the same trading day. Further, it also talks about the backtesting and importance of backtesting in creating trading strategies. Live trade or paper trade the strategies learnt in the course with a single click of the button.
Introduction to Python
This section will help you update your knowledge of Python with simple exercises on implementing functions, and manipulating dataframes using Numpy and Pandas libraries. The Quantra environment ensures that you don’t have to install anything for the Jupyter notebooks to function.Uninterrupted Learning Journey with Quantra2mNeed for Python3m 7sPreference for Python2mFunctionality of Python2mHow to Use Jupyter Notebook?1m 54sPrint Statement5mMy First Jupyter Notebook10mGetting Started with Interactive Exercises5mOperations and Functions in Python10mDivide Two Numbers5mPandas Dataframe2m 22sFunction Call5mDataFrame Axis Label2mDataFrame and Basic Functionality10mDataFrame Syntax2mDropping/Deleting Columns2mCreate Pandas DataFrame5mDataFrame Indexing2mPrint Columns2mAccess Elements of a DataFrame5mAdd New Column to a DataFrame5mSet Column as Index5mAdd Values of a Column5mAdditional Reading10m- Financial Market Data and VisualisationAn important component of a successful strategy is the data set used. In this section, you will learn how to import the correct data from various web resources, so that you can work on your own unique strategy.Importing Data1m 44sCorrect Syntax for Importing Stock Data2mImporting Time Series Data10mImport Data from Yahoo! Finance5mData Visualisation10mPlot Line Graph5mPlot Bar Graph5mAdditional Reading10mFrequently Asked Questions10m
- Basics of Financial MarketsThis section covers the basics of the financial market concept, which includes types of financial instruments, frequently used financial market jargons.Precap of Financial Markets2m 51sIntroduction to Financial Markets1m 45sFinancial Markets2mFinancial Markets and the Web2mIntroduction to Financial Instruments2m 18sDebt Instruments2mFinancial Market Jargon3m 27sDowntrend Market2mSquare Off Transaction2m
Intraday Trading
Day trading or intraday trading is a very popular trading style among traders. In this section, learn the basic building blocks of day trading and its advantages over long term investing. Also, learn to select stocks from the universe which are optimal for day trading. The right stock selection helps us avoid unnecessary risk and maximise our strategy returns.Overview of Intraday Trading2m 49sDay Trading2mDay Trading and Investing2mPreference for Day Trading2mExample of Day Trading2mHow to Create a Stock Universe1m 54sNeed of a Stock Universe2mCriteria for Stock Universe2mAverage Dollar Value2mPenny Stocks2mShortlist Stocks2mApply Criteria for Selecting Stocks10mRead Price Data5mCalculate Average Price of the Stocks5mFilter Penny Stocks5m- Momentum Trading StrategiesMomentum trading is a technique where traders buy or sell according to the strength of price trends. This section covers what, why, and types of momentum trading strategies. Further, you will learn the concept of gap-up and gap down and create a momentum day trading strategy using that concept. You will also learn a technique to optimise trading signals and improve strategy returns.Momentum Trading Strategies2m 19sPrinciple of Momentum2mWhy Momentum Exists?2mTypes of Momentum Strategies2mCross-Sectional Momentum2mGap-Up and Gap-Down2m 40sReasons for Gap Creation2mWhat is Gap-Up2mApplication of Gap Strategy2mGap Strategy10mFAQs - Gap Strategy2mCalculate Adjusted Open Price5mSet Condition for Long Position5mGenerate Buy Signals5mCalculate Strategy Returns5mPlot Cumulative Strategy Returns5mImproved Gap Strategy10mCalculate Rolling Standard Deviations5m
- Analyse Strategy PerformanceThis section teaches you to analyse the performance of the strategies. You will learn about a library called pyfolio, which is used to analyse performance and risk of financial portfolios. You will learn about Sharpe ratio, maximum drawdown, annualised volatility to analyse your strategy in-depth and from a different perspective.Analyse Strategy Performance5mPyfolio Function to Analyse Strategy Performance2mCalculate Annualised Returns2mAdditional Reading10mTest on Intraday Trading Strategies12m
- Live Trading on BlueshiftThis section will walk you through the steps involved in taking your trading strategy live. You will learn about backtesting and live trading platform, Blueshift. You will learn about code structure, various functions used to create a strategy and finally, paper or live trade on Blueshift.Section Overview2m 19sLive Trading Overview2mVectorised vs Event Driven2mProcess in Live Trading2mReal-Time Data Source2mBlueshift Code Structure2m 57sImportant API Methods10mSchedule Strategy Logic2mFetch Historical Data2mPlace Orders2mBacktest and Live Trade on Blueshift4m 5sAdditional Reading10mBlueshift Data FAQs10m
- Live Trading TemplatePaper/Live Trading Gap Up and Down Strategy10mBlueshift FAQs10m
Post Earnings Announcement Drift
After the earnings announcements of a company, sometimes there is an unusual movement in the price of that company. This section covers the concept of post-earnings announcement drift, how to capture that drift, and create a trading strategy based on the same idea on single and multiple stocks.Post Earnings Announcement Drift2m 6sWhat is PEAD?2mWhy Use Standard Deviation?2mRetrieve Earnings Announcement Data2mPEAD Strategy on Single Stock10mSelect Labels From Column5mTime of Earnings Announcements2mPEAD Strategy on Portfolio10mAdditional Reading10mScalping
Scalping is a trading paradigm where we take positions for a short period of time. This is primarily done to avoid adverse market events like unfavourable news. This section gives an overview of the need and advantages of scalping. This is brought out using the implementation of a minute level ATR based scalping strategy. The optimisation of exit thresholds, stop-loss and profit-taking, is also something this section deals with.Introduction to Scalping2m 26sConcept of Scalping2mMotivation of Scalping2mEssential Components of a Scalping Strategy2mATR Scalping Strategy3m 14sTrue Range Measure2mCalculate True Range2mRolling Mean of Window2mSet Intraday Stop-Loss and Take-profit2mATR Scalping Strategy10mCalculate Average True Range5mDetermine ATR Breakout5mCalculate Three Candle High Price5mDetermine Three Candle High Breakout5mGenerate Buy Signals5mCalculate Take Profit Price2mCalculate Stop Loss Price2mExit Optimisation3m 17sHigher Threshold2mImportance of Stop-loss2mExit Optimisation10mSet Exit Thresholds5mPaper/Live Trading ATR Scalping Strategy10mAdditional Reading10m- Automate Trading Strategy Using IBridgePyThis section deals with the steps required to automate the trading strategy for real trading using IBridgePy.Additional Reading10mSample Strategy to Run on Interactive Brokers2m
- High Frequency Trading StrategyThis section introduces the basics of market microstructure. This includes the fundamental exchange order types, the concept of ticks, bid-ask spreads and order books. The section culminates by describing in detail an HFT ticking strategy.Exchange Order Types2mOrder Type Preference for Long Term Investor2mTypes of Orders in Order Books2mOrder Book Parameters1m 27sConcept of a Tick2mBid-Ask Spread2mOrder Book2m 47sBuy Market Order2mSell Limit Order2mSell Limit Order II2mTicking Strategy3m 6sBuy or Sell Pressure2mBid-Ask Spread2mWhy a Two-tick Spread?2mExiting a Ticking Strategy2mLoopholes in a Ticking Strategy2mAdditional Reading10m
Risk Management
Risk management is a very important aspect of day trading. It helps a trader from losing all his capital. This section covers the various methods of risk management. You will learn how to minimise risk by position sizing, setting stop-loss and take-profit thresholds and thoroughly backtesting the trading strategy before live trading.Risk Management1m 56sRisk Management Strategy2mPosition Sizing2mImplementation of Stop Loss2mPodcast: Brian Blandin10m 6sAdditional Reading10mTest on Day Trading Concepts10mOvernight Returns Strategy (Bonus Content)
- Run Codes Locally on Your MachineLearn to install the Python environment in your local machine.Python Installation Overview2m 18sFlow Diagram10mInstall Anaconda on Windows10mInstall Anaconda on Mac10mKnow your Current Environment2mTroubleshooting Anaconda Installation Problems10mCreating a Python Environment10mChanging Environments2mQuantra Environment2mTroubleshooting Tips For Setting Up Environment10mHow to Run Files in Downloadable Section?10mTroubleshooting For Running Files in Downloadable Section10m
- Course SummaryThis section includes a course summary and downloadable zipped folder with all the codes and notebooks for easy access.Course Summary2m 25sPython Codes and Data2m
- IntroductionLearn the application and effectiveness of volatility based trading strategies. You will be guided through the course structure and the various concepts covered in this course. Also, you can explore the various features that are available to you on Quantra.
Entry Signals
In this section, you will learn about the moving average crossover strategy. You will learn to generate entry signals using moving average crossover.Section Overview3m 8sMoving Average Crossover4m 17sFeatures of Moving Average2mCalculate Moving Average2mHow to Use Jupyter Notebook?1m 54sDetermine the Entry Points10mGetting Started5mEntry Signals2mCalculate SMA5m- Fixed SL & TPExiting using fixed stop-loss and fixed take profit is the simplest way of exiting an open position. In this section, you will learn how to implement the same in python.Exit Using Fixed Stop-Loss and Take Profit10mCalculate Fixed Stop-Loss5mCalculate the Trading Cost5m
ATR
In this section, you will learn about a volatility based indicator called The Average True Range (ATR). You will learn to calculate the True Range and Average True Range to measure stock volatility.Measuring Volatility using ATR2mDays Range2mProperties of True Range2mCalculate True Range2mATR Indicator2mCalculate ATR2mThe Magnitude of ATR2mAdditional Reading for ATR10mSL & TP using ATR
In this section, you will learn how ATR can be used to determine the exits. Calculating stop-loss and take profit prices will be explained with examples.ATR to Determine Exits4m 44sLimitation of Fixed Percentage Approach2mATR Value2mATR for Exits2mPossible Range2mBenefits of Dynamic Exits2mDetermine Stop-loss2mReset Stop-loss2mExit Using ATR10mCalculate ATR for a Stock5mDynamic Stop-Loss5mComparison Between Fixed and Dynamic Approaches10mLimitations of ATR10mCompare ATR Values2mVolatility and Price Change2mCompare Volatility2mAdditional Reading for SL & TP using ATR10m- Live Trading on BlueshiftThis section will walk you through the steps involved in taking your trading strategy live. You will learn about the backtesting and the live trading platform, Blueshift. You will learn about code structure, various functions used to create a strategy and finally, paper or live trade on Blueshift.Uninterrupted Learning Journey with Quantra2mSection Overview2m 19sLive Trading Overview2mVectorised vs Event Driven2mProcess in Live Trading2mReal-Time Data Source2mBlueshift Code Structure2m 57sImportant API Methods10mSchedule Strategy Logic2mFetch Historical Data2mPlace Orders2mBacktest and Live Trade on Blueshift4m 5sAdditional Reading10mBlueshift Data FAQs10m
Live Trading Template
This section includes a template of a trading strategy that can be used on Blueshift. This live trading strategy template uses moving average crossover for entry signals and ATR for exit signals. You can tweak the code by changing securities or the strategy parameters. You can also analyse the strategy performance in more detail.- Measuring Volatility Using Standard DeviationThis section introduces you to the concept of standard deviation. You will learn to calculate standard deviation and use standard deviation to measure stock volatility.Standard Deviation2m 41sIntuition of Standard Deviation2mComparing Standard Deviation2mMeasuring Volatility2mCalculation of Standard Deviation2m 5sCalculate Standard Deviation of a Stock5mStandard Deviation Formula2mVariables of Standard Deviation Formula2mMean and Standard Deviation2mAdditional Reading on Standard Deviation10m
- Applications of Standard Deviation In TradingIn this section, you will learn the applications of standard deviation in trading. Calculating trading range and deciding exit parameters using the volatility will be explained with examples.How to Use Standard Deviation In Trading?3m 6sStandard Deviation of a Stock2mTrade Parameters Using Standard Deviation2mVolatility Based Stop Loss2mTest on Volatility and Standard Deviation14m
Bollinger Bands
This introduced you to the most used volatility-based trading indicator, Bollinger Bands. You will learn to calculate Bollinger Bands. You will also learn to interpret Bollinger Bands to study the price and volatility of an asset.Bollinger Bands Calculation4m 44sFormulas of Bollinger Bands10mBasics of Bollinger Bands2mMoving Average2mDefinition of Bollinger Bands2mCalculate Bollinger Bands of a Stock5mInterpretation of Bollinger Bands2m 55sEntry and Exit Conditions of Oversold Trading Strategy10mBollinger Bands Study2mElements of Bollinger Bands2mOversold Condition2mOversold Trading Strategy10mOversold Strategy Signals5mAdditional Reading on Bollinger Bands10m- Bollinger Bands PhasesIn this section, you will be introduced to the concept of Bollinger bandwidth. You will learn to study the volatility cycles using the Bollinger Band phases. All four types of Bollinger Band Phases are explained in detail to give you an intuitive understanding.Interpretation of Bollinger Bands Phases5m 20sFormulas of Bollinger Bands Phases10mBollinger Squeeze2mBollinger Phases2mVolatility Cycle2mAdditional Reading on Bollinger Bands Phases10m
Breakout Strategy
In this section, you will understand how to create a trading strategy using Bollinger Band phases. You will learn the entry and exit conditions of the breakout trading strategy designed using the Bollinger Band Phases.Breakout Strategy Using Bollinger Phases6m 54sLong Entry and Exit Rules of Breakout Strategy10mPhase Transition2mLong Breakout Entry Conditions2mVolatility Transition2mBreakout Strategy Implementation10mBB Bandwidth5mEntry Signals5mExit Signal5mAdditional Reading on Breakout Strategy10mBreakout Strategy Blueshift Live/Paper Trading Template10mVIX
Introduction to VIXVolatility During Unexpected Events2mLong Term Effect of Volatility2mVolatility Based Trading2mHedge Index Futures2mPosition in VIX Decline2mTypes of Volatility1m 38sProperty of Implied Volatility2mInterpretation of VIX3m 39sMaximum Value of VIX2mInterpretation of Implied Volatility2mDaily Volatility Using VIX2mVIX and Low Volatility2mAnnualised VIX2mVIX Level Interpretation2mVolatility in Different Time Periods Using VIX2mTypes of VIX1m 47sVolatility Index and S&P5002mTrade Gold VIX Futures2mVIX and Eurozone Volatility Index2mWebinar Snippet - Introduction to Volatility8m 40sWebinar Snippet - Why Is VIX Called the Fear Index?7m- More on VIXCalculation of VIX5m 40sOption Premium During Uncertain Periods2mInclusion of Options Based on Time of Expiry2mExclusion of Options Based on Time of Expiry2mInclusion of Options Based on Moneyness2mType of Options in VIX2mInclusion of Options Based on Bids2mInclusion of Options Based on Consecutive Bids2mProperties of VIX2mCorrelation of VIX and S&P5002mVIX Time Series2mImpact of Positive News on VIX2mVIX Derivatives2mHedge on VIX Futures2mIdentification of VIX Derivatives2mRelationship Between VIX ETNs and VIX Futures2mAdditional Reading10m
- Hedging Using VIXIn this section, you will understand the inverse relationship between VIX and S&P 500. You will learn about the concept of hedge ratio. Further, you will apply the concept of hedge ratio to create a hedging strategy using VIX ETF.Hedging With VIX ETF2m 13sFall in S&P 5002mHedging the Losses2mHedge Ratio2mHedge Ratio - Always a Fixed Value?2mDetermine Hedge Ratio2mPortfolio Hedging Using VIX10mCompute Strategy Parameters5mCalculate Daily Strategy Returns of Combined Portfolio5m
- Selective Long on VIXIn this section, you will improvise on the previous strategy by going selective long on VIX. You will also discover different ways to select when to go long on VIX.Selective Long VIX Strategy5m 12sIdentify Best Performing Assets2mAlways Long on VIXY2mVIXY Monthly Returns2mImprove Strategy Performance2mVIX Levels2mDrawbacks of Fixed VIX Value2mCapture Panic Dynamically2mSMA for Entry2mExit Conditions2mAvailable Cash In Selectively Long Strategy2mSelectively Long Strategy Returns2mCompare Selectively Long with S&P 5002mGoing Selectively Long on VIX10mGenerate Buying Signal5mSelective Long on VIX Blueshift Live/Paper Trading Template10m
- VIX SpreadVIX Spread Concept2m 52sVIX Spread Strategy10mFAQ10mTest on Bollinger Bands and VIX16m
- Understanding BetaIn this section, you will understand the concept of beta and what it is used for. You will learn about systematic and unsystematic risk. You will also discover what type of risk is measured by beta and how beta values are interpreted.Beta and Its Interpretation2mAdditional Reading for Drawbacks of Beta10mIdentify the Type of Risk2mDefine Beta2mIdentify Beta Value2mInterpretation of Beta - I2mInterpretation of Beta - II2mMatch the Beta Value - I2mMatch the Beta Value - II2mSelect a Stock Based on Beta2m
- Calculating BetaThis section explains how to calculate beta using the linear regression model with the help of Python. You will learn about the elements of the regression equation. You will also understand how to get the beta coefficient from a linear regression model.Pre-reading10mHow to Calculate BetaDefine the Variables2mDescribe the Element2mDefine the Slope of Line2mIdentify Approximate Beta2mIdentify the Linear Regression Equation2mIdentify the Beta Value2mIdentify Correlation2mIdentify Volatility2mIdentify the Relevance of Beta2mIdentify the Independent Variable2mCalculate Beta With Python10mIdentify the Number of Trading Days2mAdd the Constant Term5mCalculate Beta5mFetch the Values5m
Betting Against Beta
In this section, you will learn about the premise of the “Betting Against Beta” strategy. It includes a simple explanation of the author’s hypothesis. It also includes the steps that are required to implement the strategy.Application of Beta2mDescribe the Use of CAPM2mDefine Risk-free Rate of Return2mDefine Market Risk Premium2mDescribe the Theory of CAPM2mCalculate Expected Returns2mBetting Against Beta3m 35sIdentify the Valuation2mDefine the BAB Strategy2mDescribe the Hypothesis2mDefine Alpha2mSelect a Stock to Buy2mResearch on BAB
This section attempts to validate the author’s hypothesis of the “Betting Against Beta” or the BAB strategy. This is done by testing the strategy on the past data of S&P 500 stocks and checking if it works by analysing the past performance of these stocks.Research on BABData for Calculating Beta2mDescribe Strategy Testing2mSteps to Implement the BAB Strategy2mIdentify the Order of Ranking2mIdentify the Criteria of Bucket Creation2mResearch on BAB - I10mSplit the data into train & test5mCalculate Beta for Multiple Stocks5mCreate Stock Buckets5mCalculate Average Returns for Each Bucket5mResearch on BAB - II10mBacktesting BAB
This section will teach you how to backtest a modified strategy based on the research made on the BAB paper in the previous section. On this opportunity, you will go long on high beta stocks to check whether we can be profitable with them. Data will be provided from 2015 to 2022.BAB Backtesting - I10mIdentify the Function2mCalculate the Returns of the Chosen High Beta Stocks5mBAB Backtesting - II10mTest on Beta10m- Run Codes Locally on Your MachineIn this section, you will learn to install the Python environment on your local machine. You will also learn about some common problems while installing python and how to troubleshoot them.Python Installation Overview2m 18sFlow Diagram10mInstall Anaconda on Windows10mInstall Anaconda on Mac10mKnow your Current Environment2mTroubleshooting Anaconda Installation Problems10mCreating a Python Environment10mChanging Environments2mQuantra Environment2mTroubleshooting Tips for Setting Up Environment10mHow to Run Files in Downloadable Section?10mTroubleshooting for Running Files in Downloadable Section10m
- Capstone ProjectThis section will help you to develop a breakout strategy learnt in the Bollinger Bands section in order to identify the top 5 stocks from the S&P 500 that perform well from 2010 to 2022.Capstone Project: Getting Started10mProblem Statement10mFrequently Asked Questions10mCode Template and Data Files2mCapstone Project Model Solution10mCapstone Solution Downloadable2m
- Course SummaryIn this section, we will summarise all the volatility trading concepts and strategies that you have learned throughout the course. By the end of this section, you will get an idea of what you can do next to further improve your trading skills.Summary4m 49sCourse Summary and Next Steps10mPython Codes and Data2m
- IntroductionBacktesting helps to evaluate a trading strategy from different perspectives. The interactive methods used will help you not only grasp the concepts but also answer all questions related to backtesting. This section helps you understand the course structure, and the various teaching tools used in the course: videos, quizzes, coding exercises and also the capstone project.
Backtesting
With backtesting, we can evaluate any of our trading strategies objectively. In this section, you will familiarise yourself with the complete process of backtesting. And you will also explore the key difference between backtesting and simulation.What is Backtesting?2m 22sDoes Past Reflect Future?2mBacktesting Technique2mBacktesting vs Simulation4m 57sSimulated Data2mGenerate Simulated Data2mDataset for Backtest2mWhen to Use Simulated Data?2mBest Approach to Backtesting2mBacktesting Process2m 21sSteps in Backtesting2mEvaluate the Performance of Backtesting2mNeed for Backtesting2mDrawbacks of Backtesting2mAdditional Reading10m- Financial DataThe very first step to backtesting any trading strategy is to get the right data. In this section, you will learn about the different types of financial data that are available. You will also learn to fetch and store the correct data from various web resources. And lastly, you will understand the limitations of working with financial data.Financial Data2mStructured Financial Data2mFrequency of the Data2mDerivatives Data2mData for Long-term Strategies2mMacroeconomic Data2mUse of Sentiment Data2mFinancial Data Storage4m 28sStorage Technique - I2mStorage Technique - II2mIdeal Storage Method2mHow to Use Jupyter Notebook?2m 5sDaily Stock Price Data5mAdjusted Data2mHow to Use Interactive Exercises?5mFetch the Daily Stock Price Data5mLimitations of Financial Data4m 15sKey Limitation2mOvercome the Limitation2mAdditional Reading10m
- Data Pre-ProcessingValidating the data and performing sanity checks are important processes to use before backtesting = that must not be overlooked. In this section, you will touch upon some techniques that can be used to validate your dataset. Learn to handle missing data. You will also learn about the concept of survivorship bias and ways to overcome this challenge.Data Pre-Processing3m 56sData Pre-Processing Steps2mData Quality Checks2mDiscrepancies in Data2mData Quality Checks and Data Cleaning10mCheck for NaN Values5mDrop Missing Values5mIdentify Duplicate Values5mDrop Duplicate Values5mSurvivorship Bias4m 33sSurvivorship Bias and Trading2mOvercome Survivorship Bias2mAdditional Reading10mTest on Creation of a Backtest10m
Trading Rules
To build a strategy, it’s necessary to have an idea and formulate rules based on these ideas. In this section, you will learn how an idea is converted into the entry and exit rules. These rules act as the foundation for the strategy, you will also learn how they are used to generate trading signals.Developing Trading Rules1m 57sDefine Trading Rules2mIdentify Characteristics of Trading Rules2mIdentify Trading Rules2mImplementing a Trading Strategy2mRule Formulation2mIdentify the Correct Rule2mEntry and Exit Rules3m 22sNeed for Backtesting2mGenerate Entry and Exit Signals10mShort-Term Moving Average5mTrading Signals5mStrategy Returns5mBacktest and Generate Trade Sheet10mLong Crossover Condition2mTrade Information of a Long Entry2mPnL of Long Trades5m- Trade Level AnalyticsTo understand whether your strategy is working, you need to analyse certain metrics. Trade level analytics are computations that depict how well the strategy has performed over a certain period of time. In this section, you will be learning how to calculate and interpret a few widely used analytics.Trade Level Analytics I5mTrade Level Analytics II4m 21sDefine Win Trades2mCalculate Win/Loss Rate2mCalculate Average PnL Per Trade2mIdentify the Correct Strategy-I2mIdentify the Correct Strategy-II2mLimitations of Win Trade2mCalculate Average Trade Duration2mInterpret the Profit Factor2mCalculate the Profit Factor2mTrade Level Analytics10mAverage PnL Per Trade5mLimitations of Profit Factor2mWin Percentage5mAverage Trade Duration5mAnalyse the Strategy Performance2mAdditional Reading10m
- Performance MetricsThe performance of a strategy is determined not only by its returns but also, by its risk. In this section, you will learn how to evaluate the performance of your strategy based on returns, risk and both. You will learn about some key performance metrics such as Sharpe ratio, CAGR, and maximum drawdown, as well as how to compute and implement them in Python using the Jupyter notebook.Equity Curve and CAGR3m 53sEquity Curve2mEquity Curve Interpretation2mCAGR Calculation2mCAGR and Average Annual Return2mStrategy Returns2mSharpe Ratio2m 10sSharpe Ratio of a Strategy2mSharpe Ratio Calculation2mStrategy Comparison2mDrawback of Sharpe Ratio2mMaximum Drawdown2m 27sMaximum Drawdown Calculation2mMaximum Drawdown Comparison2mMaximum Drawdown of a Strategy2mPerformance Metrics10mFAQ on Cumulative Returns2mCAGR5mSharpe Ratio5mMaximum Drawdown5mAdditional Reading10m
- Risk ManagementRisk management is one of the key elements of a trading strategy. The performance of a trading strategy can be improved with the help of risk management. In this section, you will be learning how to bring down the level of risk of your strategy by applying methods like stop-loss and take-profit levels. You will learn how these levels protect you from extreme losses.Stop-Loss and Take-Profit5mControl the Trading Losses2mApplying Risk Management2mRisk Management of a Long Trade2mNeed for Stop-Loss and Take-Profit2mGuidelines For Setting Stop-Loss and Take-Profit3m 27sCorrect Stop-Loss and Take-Profit2mRisk Management Parameters2mStop-Loss and Take-Profit Orders2mBacktest With Stop-Loss and Take-Profit10mStop-Loss of Long Trades5mTake-Profit of Long Trades5mAdditional Reading10m
Transaction Costs and Slippage
The journey towards building a good backtest for a strategy idea is incomplete without considering the transaction costs and slippages. In simple words, transaction costs encompass brokerage, commission, etc. Slippage is the difference between the expected and executed price. Learn these concepts and understand how to incorporate them into your backtesting code.Transaction Costs and Slippage2mCalculation of Transaction Cost2mCalculation of Slippage2mImplementation of Transaction Cost and Slippage10mAdditional Reading10mPaper Trading
Once you have built your backtest and are satisfied with the performance of your strategy, you can move to the next step, paper trading. Paper trading has evolved from simple writing of buy and sell prices on a notepad to a full-fledged system environment which replicates the live trading environment. Learn the importance of paper trading and how it strengthens your confidence in the strategy.Introduction to Paper Trading4mDecrease in Performance During Paper Trading2mSharpe Ratio in Paper Trading2mCost Difference Between Backtesting and Paper Trading2mThings to Keep in Mind While Paper Trading3m 17sReasons for Paper Trading2mAsset Difference in Paper Trading2mChange in Entry Rules in Paper Trading2mReasons to Stop Paper Trading2mReason to Move From Paper to Live Trading2mAdditional Reading10mTest on Evaluation of Strategy12m- Live Trading on BlueshiftLearn how you can take your backtested strategy live with some important steps. Learn about the code structure, the various functions used to create a strategy, and finally, paper or live trade on Blueshift.Uninterrupted Learning Journey with Quantra2mSection Overview2m 19sLive Trading Overview2m 41sVectorised vs Event Driven2mProcess in Live Trading2mReal-Time Data Source2mBlueshift Code Structure2m 57sImportant API Methods10mSchedule Strategy Logic2mFetch Historical Data2mPlace Orders2mBacktest and Live Trade on Blueshift4m 5sAdditional Reading10mBlueshift Data FAQs10m
- Live Trading TemplateThis section includes a template of a trading strategy that can be used on Blueshift. This live trading strategy template uses moving average crossover to generate entry and exit signals. You can tweak the code by changing securities or the strategy parameters. You can also choose the asset and the duration of backtesting, and analyse the strategy performance in more detail.Paper/Live Trade Using Moving Averages10mFAQs for Live Trading on Blueshift5m
Common Pitfalls in Backtesting
There exist various biases in Backtesting which include look-ahead, overfitting, and data snooping biases. Learn how to overcome them, and check out the common mistakes while backtesting. Finally, even if your strategy is successful and has been validated by backtesting it, you can never over-rely on it. We explain this with the help of a real-life case study.Biases to Avoid4m 7sExamples of Look Ahead Bias2mPaper Trading Based on Exceptional Returns2mExample of Overfitting2mCommon Mistakes Done With Trading Volume3m 19sNumber of Shares Bought on Basis of Volume2mDefinition of Illiquid Stock2mTrading Based on Volume2mStrategy Decision Using Volume2mData Snooping3m 43sExample of Data Snooping2mMinimisation of Data Snooping2mMultiple Iterations on Out of Sample Data2mStrategy Performance on In Sample and Out of Sample Data2mOver Reliance on Backtesting2m 12sReason of High Leverage in Trading2mPossible Flaw in Strategy Idea2mReason for Not Over Relying on Backtesting2mMinimise Effect of Extreme Events on Portfolio2mAdditional Reading10m- FAQsIn this section, we address some of the most frequently asked questions about backtesting.Ideal Time Period for Backtesting2mNumber of Assets to Backtest On2m 24sRisk Metrics and Sharpe Ratio3m 1sPaper and Live Trading3m 48s
- Capstone ProjectThis section will help you to develop a moving average crossover strategy and backtest it. You will also create an equal-weighted portfolio and compute its performance metrics.Capstone Project: Getting Started10mProblem Statement10mFrequently Asked Questions10mCode Template and Data Files2mCapstone Project Model Solution10mCapstone Solution Downloadable2m
- Run Codes Locally on Your MachineIn this section, you will learn to install the Python environment on your local machine. You will also learn about some common problems while installing python and how to troubleshoot them.Python Installation Overview1m 59sFlow Diagram10mInstall Anaconda on Windows10mInstall Anaconda on Mac10mKnow your Current Environment2mTroubleshooting Anaconda Installation Problems10mCreating a Python Environment10mChanging Environments2mQuantra Environment2mTroubleshooting Tips for Setting Up Environment10mHow to Run Files in Downloadable Section?10mTroubleshooting for Running Files in Downloadable Section10m
- Course SummaryIn this section, we will briefly summarise everything that you have learned in this course.Summary2mCourse Summary and Next Steps2mPython Codes and Data2m
- Introduction to the CourseIn this section, you will go through a brief overview of the concepts taught in the course in a structured format and also explore the various features of Quantra Platform.
- Introduction to Market DataHow many times have you thought to yourself, I have a hypothesis or a strategy, but where do I get the data to test it? In this section, we will answer some of the most common questions as well as download equity, forex, and cryptocurrency data from a python library.Understanding Market Data and Storage Needs2mData Sources for Market Information5mHow to Get Market Data5mGetting API Keys from Alpaca2mGetting Data From Alpaca API5mResources for Downloading Financial Data2m
- Storing Data: CSV or DatabaseYou must be thinking, why do you need a database when your work can be done using a CSV, Excel or JSON file for storing data. In this section we will look at a few use cases and check whether you should use a CSV or a database would be more appropriate.Storing Data: CSV or Database2mHandling Large Datasets5mData Storage Options5mData Integrity5mCollaborative Data Sharing5mPerformance and Multi-Threading5mAdditional Reading on Storing Data: CSV or Database2mSummary on Storing Data: CSV or Database2mTest on Retrieval of Data and Use of Database16m
Introduction to a Database
In this section, you will learn the components of a database as well as its types. You will also go through a brief overview of database components.Introduction to a Database2mIntroduction to Databases5mData Organisation and Retrieval5mApplications in Trading5mData Validation5mBrief Overview of Database Components2mDatabase Components5mTable Structure5mUnique Identifiers5mUniqueness in Data5m- Primary and Foreign KeysIn this section, we will delve a bit deeper into the reason why database can retrieve data faster through the concept of primary and foreign keys.Primary Keys and Foreign Keys2mDatabase Keys Fundamentals5mLinking Tables with Keys5mData Organisation in Databases5mCustomising Primary Keys5mRelational Database Examples5mTest on Database Components and Keys18m
- Other Types of DatabasesDo you think there are only relational Databases? Not likely. In this section, you will look at two more types of databases and why are they important.Other Types of Databases2mTime Series Databases5mIndexing in Time Series Databases5mBenefits of Time Series Databases5mRelational Database Fundamentals5mBenefit of Indexing in Time Series5mNoSQL Databases2mData Classification5mSource-Specific Fields5mNoSQL Definition5mFAQs on Other Types of Databases2mAdditional Reading on Other Types of Databases2mSummary on Other Types of Databases2mTest on Other Types of Databases14m
Creating Database
Learn the different architectures used in databases, such as file-based, server-based, local, and cloud setups. Explore beginner-friendly tools like SQLite and combine them with SQLAlchemy to make your database easily migratable.Section Overview: Creating Database2mThe Beginner's Toolkit SQLite and SQLAlchemy2mWhy SQLite ?5mWhy Not SQLite?5mWhy SQLAlchemy?5mServer-Based Database2mKey Advantage of Server-Based Database5mWhy Host?5mSeamless Database Transition.5mDatabase on Cloud2mCloud Benefits5mKey Advantage of Cloud Databases5mCloud Database Security5mInitialising Database5mExecute create_engine5mSQLite and PostgreSQL5mThe Flexibility Provided by SQLAlchemy5mFAQs on Creating Database2mAR on Creating Database2mConcepts of Database Types and Beginner Toolkits16mSummary Creating Database2m- Schema DesignUnderstand how to structure tables, keys, and relationships for effective data storage.Schema Design Essentials2mWhy create more tables?5mWhy separate OHLC columns?5mWhy Use Composite Keys ?5mWhy separate different timeframe data?5mFAQs on Schema Design2mAdditional Reading on Schema Design2m
- Creating the SchemaTurn your schema design learnings into real database tables. You'll define structure, keys, and indexes to make your SQLite database ready for the data.Section Overview on Creating the Schema2mUnderstanding the Data2mWhy Datatypes?5mForeign Key in the Minute-level Data5mWhy Avoid Indexing All Columns?5mCreating Tables with SQLAlchemy2mSQLAlchemy Schema Steps Order?5mSQLAlchemy Engine Object Role?5mSQLAlchemy MetaData Importance?5mCreating Tables5mFAQs on Creating the Schema2mAdditional Reading on Creating the Schema2mTest on Creating the Schema14mSummary on Creating the Schema2m
- Inserting Data into a DatabaseOnce you have created the database, insitialised it and also created tables, you are now ready for the next step, which is inserting data in the database. In this section, you will see how to use real-world data and insert this data correctly in the database without any errors.How to Insert Data Into a Database2mOrder of Insertion of Data to Tables5mRemoval of Timezone Information5mBegin Engine Connection5mInserting Data in Database5mDatabase Connection and Table Reflection5mSQLAlchemy and Data Insertion5mSymbol Comparison Logic5mFAQs on Inserting Data into a Database2mSummary on Inserting Data into a Database2mTest on Inserting Data in Database10m
- Structure of Options Chain DataLearn the structure of options chain data and how to use it effectively. Understand key components like strike, expiry, and Greeks, compare data formats across sources, and plan your own options chain database.Section Overview of Structure of Options Chain Data2mStructure of Options Chain Data2mUnderstanding the Structure of Options Chain Data5mComponents of Call Option Data5mData Consistency Across Providers5mAdditional Columns in Options Chain Data5mInitial Step for the Options Database5mFAQs on the Structure of Options Chain Data2mAdditional Reading on Structure of Options Chain Data2mSummary of Structure of Options Chain Data2mTest on Structure of Options Chain Data14m
- Sourcing and Cleaning the Options Chain DataLearn to clean and structure raw options chain data by fixing column names, data types, missing values, and hidden formatting issues, ensuring it’s ready for accurate analysis and strategy building.Section Overview: Sourcing and Cleaning the Options Chain Data2mData Vendors10mSourcing US Options Data2mCleaning the Data2mImportance of Data Cleaning5mIdentifying Unwanted Elements in Column Names5mStandardising Column Name Casing5mResolving Data Inconsistencies2mPurpose of Resolving Data Inconsistencies5mIdentifying Duplicate Rows5mImportance of Data Type Validation5mHandling Inconsistencies in Float-Type Columns5mExtracting and Cleaning Options Data5mRemoving Leading Spaces from Column Names5mRemoving Square Brackets from Column Names5mConverting Column Names to Lowercase5mFAQs on Sourcing and Cleaning the Options Chain Data2mSummary of Sourcing and Cleaning the Options Chain Data2mTest on Sourcing and Cleaning the Options Chain Data14m
Structuring and Filtering the Options Data
Learn to structure and filter raw options data by categorising expiry types and removing illiquid or irrelevant contracts, preparing it for analysis and strategy development.Section Overview: Structuring and Filtering the Options Data2mClassifying Options Data Based on Expiry2mPurpose of Expiry Categorisation5mWeekly Expiry Definition5mLEAPS Classification5mFiltering the Options Chain Data2mIlliquid Contracts5mDeep ITM/OTM Filtering5mWhen the Bid or Ask Price is Zero5mFiltering the Options Data5mFAQs on Structuring and Filtering the Options Data2mAdditional Reading on Structuring and Filtering the Options Data2mSummary of Structuring and Filtering the Options Data2mTest on Structuring and Filtering the Options Data14mStoring Options Chain Data
Learn how to organise and store options chain data efficiently in a SQL database, focusing on modular table design, translating Pandas DataFrames to SQL, and ensuring data integrity through best practices.Section Overview: Storing Options Chain Data2mStructure of Options Database2mSingle Table vs. Separate Tables5mDatabase Structure Decision5mSQL Data Types5mStoring the Options Chain Data2mQuery Performance5mSQL Table Structure5mUse Case Alignment5mStoring Options Data5mCreating SQL Tables with Appropriate Columns and Data Types5mFAQs on Storing Options Chain Data2mAdditional Reading on Storing Options Chain Data2mSummary of Storing Options Chain Data2mTest on Storing Options Chain Data14m- Querying Options Chain DataLearn how to query structured options data from a SQL database using essential SQL queries to filter, select, and retrieve relevant data for backtesting and strategy analysis.Section Overview: Query Options Data from Database2mQuery Options Data from Database2mMatching Multiple Exact Values5mRetrieving Call Options Data5mAdvantages of Specific Column Selection5mQuery Options Data from Database5mCreating a Parameterised SQL Query5mCreating a Parameterised SQL Query with IN Clause5mFAQs on Query Options Data from Database2mAdditional Reading on Query Options Data from Database2mSummary of Query Options Data from Database2mTest on Querying Options Chain Data10m
- Capstone ProjectIn this section, you will apply the knowledge you have gained in the course. You will pick up a capstone project where create an options database for 1-min frequency data.Getting Started2mProblem Statement2mCapstone Data Files2mCapstone Solution2m
- When Should You Update Your Database?In this section, we ask ourselves if frequent update to the database is always a good thing or not.When Should You Update Your Database?2mDatabase Update Strategies5mReal-Time Decision-Making and Database Performance5mTiming Database Updates5mFAQs on When Should You Update Your Database2mSummary on When Should You Update Your Database2m
Multithreading
Explore the concept of parallel processing, focusing on multithreading and multiprocessing techniques to speed up tasks like financial data retrieval and backtesting by executing multiple tasks simultaneously.Introduction to Parallel Processing2mWhat is Parallel Processing?5mGlobal Interpreter Lock5mTask Suited for Multithreading5mHow to Implement Multithreading?5mStarting Threads5mPurpose of join()5mManaging Threads2mManaging Threads2mProblems with Manual Threading5mThreadPoolExecutor5mHow to Implement Threadpoolexecutor?5mFAQs on Multithreading2mAdditional Reading on Multithreading2mSummary on Multithreading2m- MultiprocessingIn the previous section, we explored one of the key parallel processing techniques—multithreading. Now, let’s turn up the intensity and dive into another powerful approach: multiprocessing. Curious how it can turbocharge your computation-heavy tasks? Let’s find out!Introduction to Multiprocessing2mBenefit of Multiprocessing5mTask Suited for Multiprocessing5mDrawback of Using Multiprocessing5mFAQs on Multiprocessing2mAdditional Reading on Multiprocessing2mSummary on Multiprocessing2mTest on Parallel Processing Techniques6m
- Fetching Bid-Ask DataTo truly understand market behavior, it's not enough to see just the last trade. By fetching Level 1 and Level 2 bid-ask data, we gain a deeper look into price action—from the top of the order book to its full depth. Explore this section to see how it's done.Market Data Levels2mLevel 1 Market Data Contents5mLevel 2 Market Data Contents5mMarket Depth5mMarket Data Cost5mFetching Level 1 Data5mFetching Level 2 Data5mAdditional Reading on Fetching Bid-Ask Data2mFAQs on Fetching Bid-Ask Dara2mSummary on Fetching Bid-Ask Data2mTest on Fetching Bid Ask Data12m
- Handling Corporate ActionsIn this section, we'll explore corporate actions and why they're crucial for maintaining accurate stock price data. From stock splits to dividends, understanding these events ensures your data stays reliable for analysis and decision-making.Corporate Actions2mStock Split5mDividend5mStock Split Adjustment5mImportance of Adjustment5mHow to Handle Corporate Actions?5mFAQs on Handling Corporate Actions2mAdditional Reading on Handling Corporate Actions2mSummary on Handling Corporate Actions2mTest on Handling Corporate Actions10m
- Run Codes Locally on Your MachineLearn to install the Python environment in your local machine.Uninterrupted Learning Journey with Quantra2mPython Installation Overview1m 59sFlow Diagram10mInstall Anaconda on Windows10mInstall Anaconda on Mac10mKnow your Current Environment2mTroubleshooting Anaconda Installation Problems10mCreating a Python Environment10mChanging Environments2mQuantra Environment2mTroubleshooting Tips for Setting-up Environment10mHow to Run Files in Downloadable Section?10mTroubleshooting For Running Files in Downloadable Section10m
- Summary of the CourseIn this section, you will go through the summary of the course and access the data files and notebooks which were used in the course.Summary of the Course2mNext Steps2mPython Codes and Data2m
- Introduction to the CourseAn event driven trading strategy systematically seeks to recognise and exploit patterns in the financial market. In this section, we will talk about event driven trading strategy, the importance of algorithmic trading research papers, and how to use these papers to create trading models.
Introduction to Event Trading Strategies
In the section, you will learn about event driven trading strategies in detail and its underlying reason. The strategy is applied only when there is a fundamental reason for the pattern and not a random coincidence. You will also learn about the advantages of event driven strategies and how an event which is known beforehand can be used to maximise gains.Seasonal Event-driven Trading Strategies2m 44sDescribing Seasonal/Calendar Trading Strategy2mAdvantage of Seasonal/Calendar Strategy2mTheory Behind Event-driven Trading Strategies2m 40sFundamental Reasons Behind Calendar Anomalies2mTurn of Month Effect in Equities
We start with one of the most common calendar anomalies in the equity markets that is the turn of the month. At the end of the month, some recognisable pattern has been observed in the equity markets. In this section, you will learn the fundamental reason behind this pattern and how to exploit this information in creating a simple trading strategy.Precap of Calendar Anomalies in Equities44sExchange Traded Fund10mETF Definition2mSPY ETF2mTrading ETFs2mTurn of Months Effect3m 46sReason for Turn of the Month2mTrading Rules for ToM2mMotivation for Trend-Following Filter2mTest on Turn of Month Effect in Equities14mTurn of Month Effect in Equities Code
This is a practice section that teaches you in a step by step manner, to implement the turn of the month trading strategy in Python. You will learn to read data, generate trading signals and analyse strategy performance of the strategy. You will also practice these codes in an easy to follow, interactive coding environment.How to Use Jupyter Notebook?2m 5sTurn of the Month Code10mFrequently Asked Questions10mRead Data From CSV5mCalculate Daily SPY Returns5mGenerate Turn of the Month Signal5mCalculate Strategy Returns5mCalculate Cumulative Returns5mPlot Cumulative Curve5mCalculate Running Maximum Value5mCalculate Drawdown5mCalculate the Rolling Mean5mGenerate SMA Signal5mStrategy Returns With Trend Factor5mTurn of the Month Effect Additional Reading10m- Live Trading on BlueshiftThis section will walk you through the steps involved in taking your trading strategy live. You will learn about backtesting and live trading platform, Blueshift. You will learn about code structure, various functions used to create a strategy and finally, paper or live trade on Blueshift.Uninterrupted Learning Journey with Quantra2mSection Overview2m 19sLive Trading Overview2m 41sVectorised vs Event Driven2mProcess in Live Trading2mReal-Time Data Source2mBlueshift Code Structure2m 57sImportant API Methods10mSchedule Strategy Logic2mFetch Historical Data2mPlace Orders2mBacktest and Live Trade on Blueshift4m 5sAdditional Reading10mBlueshift Data FAQs10m
- Live Trading TemplateBlueshift Live Trading TemplatePaper/Live Trading Turn of Month Strategy10mFAQs for Live Trading on Blueshift10m
- Payday Effect in EquitiesThe payday effect is similar to the turn of the month effect. It has been observed that the 16th day of the month is the most profitable day in a month, which leads to a trading strategy. In the section, you will learn the reason behind this effect, backtest the payday effect strategy and analyse the performance of the strategy.Payday Effect2m 47sReason for Payday Drift2mRules for Payday Effect Strategy2mPayday Effect Code10mFind 16th Day of the Month5mPaper/Live Trading Payday Effect Strategy10mPayday Effect Additional Reading10m
FED Day Effect in Equities
Federal Open Market Committee Meetings occur eight times per year and dates are well-known. There is some positive drift in the stock prices during these meetings. In the section, you will learn the reason behind this and create a trading strategy around that.FED Day Effect4m 32sTrading the FED Day Strategy2mReason for Market Drift During FOMC2mFED Trend-Following Filter2mFED Day Effect Code10mFed Meeting Date in the SPY Trading Date5mFED Day Effect Additional Reading10m- Options Expiration Effect in EquitiesDuring options expiration week, there is some unusual pattern observed in the equity markets, which leads to another calendar anomaly strategy. You will learn the reason behind this effect and create a trading strategy based on this effect.Options Expiration Effect4m 17sTrading Rules for Options Expiration Strategy2mOptions Expiration Week Market Drift2mEquity Segment in Options Expiration2mOptions Expiration Effect Code10mCalculate Min Year Value in SPY Data5mPaper/Live Trading Options Expiration Effect Strategy10mOptions Expiration Effect Additional Reading10mTest on Payday Effect, FED Day Effect and Options Expiration Effect14m
- Auction Trading Effect in Fixed IncomeTreasury prices fall for a brief period of time right before the dates of treasury bond auctions by governments. In this section, you will learn how to use this fall in price to create a seasonal trading strategy. You will also be implementing it in Python.Fixed Income Government Bonds10mGovernment Bond Risk2mGovernment Bonds Trading2mAuction Trading Effect4m 1sDefinition of Treasury Auction2mTreasury Bond Price Patterns2mMarket Drift During Treasury Auction2mAuction Trading Effect Code10mComparison of Treasury Date With Auction Date5mImplementation of Treasury Auction Conditions2mAuction Effect Additional Reading10m
- End of the Month Effect in Fixed IncomeFixed income bonds like the government bonds show statistically significant positive returns at the end of the month. This is seen particularly in bonds with longer maturity periods. This is just like in effect in equities handled in the sections before. In this section, you learn to use fixed-income ETFs to create month-end strategies to exploit this effect.End of the Month Effect3m 34sMarket Segment for EOM Effect2mTrading Rules for EOM Effect2mReason for Drift During EOM2mEnd of the Month10mCondition for Last Day of the Month5mEnd of Month Effect Additional Reading10mTest on Auction Trading Effect and End of the Month Effect14m
- Calendar Effect in Volatility MarketVIX index is a measure of perceived volatility in the market. VIX futures are traded in the market and they expire every month. We see a seasonal pattern of returns around the time of expiration which is statistically significant. In this section, you will use VIXY to implement a strategy in Python, which exploits this pattern. You will also learn ways to enhance this strategy.Concepts of Volatility Markets10mVIX Futures Expiration Effect2m 14sInstrument in Volatility Strategy2mVIX Expiration Effect Rules2mVIX Expiration Effect Drift2mVIX Futures Expiration Strategy10mComparison of VIXY Date With Expiration Date5mVIX Futures Expiration Enhancement4m 35sRisk of Short Volatility Position2mMeaning of Contango2mEnhanced VIX Futures Strategy Rules2mVIX Futures Expiration Enhanced Strategy10mComparison of VIX3M Price With VIX1M Price5mVIX Futures Expiration Additional Reading10m
- December Effect in Volatility MarketThe sentiments in the market around the holiday season in December, in general, are high. The liquidity is low. This leads to a positive trend around the time of Christmas. In this section, you will learn more about this and learn what historical data says about returns around this time. You will create a strategy in Python to exploit this seasonal occurrence. You will also learn ways to enhance the performance of your strategy using long-term VIX futures filters.December Seasonality Effect3m 2sDecember Volatility Effect Trading Rules2mReason for December Volatility Drift2mDecember Seasonality Effect10mFlagging December Expirations5mFlag Post Christmas Business Days5mType of Merge2mDecember Effect Additional Reading10mTest on Calendar Effect and December Effect14m
- Composite StrategyIn the sections, before this, you saw strategies made on equity, fixed-income and volatility instruments. In this section, you will learn multiple ways to combine these strategies to build a portfolio of strategies. The motivation is to use cash better and to create a single composite strategy which outperforms individual strategies. You will implement multiple ways to do this in Python.Introduction to Composite Seasonal Strategy2m 1sComposite Strategy - Equal Weighted1m 47sComposite Strategy - Volatility Weighted3m 15sInverse-volatility Weighting Approach2mMethodology of Composite Strategy2mComposite Strategy - Enhanced Volatility2m 8sImproving Composite Seasonal Strategy2mComposite Strategy10mCombining SPY Signals Using Max5mCalculating Weighted Cumulative Returns5m
- Composite Strategy EnhancementIn this section, you will learn about how to enhance the composite strategies you developed in the previous sections. You will also go beyond the experiments and learn about the impact of trading costs and slippages on the profitability of the composite strategy you created.Effect of Trading Cost2m 24sCalculate the Trading Cost2mCalculate the Slippage2mComposite Strategy Improvement1m 21sAdvantage of a Multi-strategy Portfolio2m
- Effect of COVID-19This section includes the effect of coronavirus pandemic on the overall market. And its impact on the performance of the composite strategy.Effect of COVID-193m 4sMovement of SPY and VIXY2mEffect on Composite Strategy2mTest on Composite Strategy and Effect of COVID-1914m
- Automate Trading StrategiesThis section deals with the steps required to automate the trading strategy for real trading using a broker's account. You will learn step by step guide to connect your trading strategy with the broker's account, fetch real & historical data, and place orders.Automation of Strategy10mPaper/Live Trading Turn of Month Strategy (IBridgePy)2mTasks Required for Live Trading2mApplication Programming Interface2mConnect Python IDE's to Broker's Terminal2m
- Run Codes Locally on Your MachineLearn to install the Python environment in your local machine.Python Installation Overview1m 59sFlow Diagram10mInstall Anaconda on Windows10mInstall Anaconda on Mac10mKnow your Current Environment2mTroubleshooting Anaconda Installation Problems10mCreating a Python Environment10mChanging Environments2mQuantra Environment2mTroubleshooting Tips For Setting Up Environment10mHow to Run Files in Downloadable Section?10mTroubleshooting For Running Files in Downloadable Section10m
- Course SummaryThis section includes a course summary and downloadable zipped folder with all the codes and notebooks for easy access.Course Summary3m 36sPython Codes and Data2m
- IntroductionUnderstand how one can implement math and statistics in financial markets to create trading strategies. This section also gives an overview of different types of learning units which comprise the course: videos, coding exercises, Python notebooks, quizzes and trading platform integrated units. You would also be taken through the course syllabus which is perfect for beginners in the domain. This entire section is available for free preview.
What is Time Series?
A time series should be recorded periodically and without any gaps. In this section learn what constitutes a time series and what does not. For example, new iPhone model announcements are not periodical and hence are not fit for time series analysis. Further, understand when a time-series analysis should be carried out.Introduction to Time Series2m 9sFinding the Time Series2mFrequency in Time Series Analysis2mData Set in Time Series2mAcquisitions in Time Series2mWhy is Time Series Analysis Required?2m 51sReasons for Time Series Analysis2mWhen Is Time Series Analysis Not Required?1m 42sScenario for Not Analysing Time Series2mSimple and Cumulative Returns
Perfect section for beginners in finance to get started with. Returns are simply the change in the prices from yesterday. Learn how returns are calculated and further, why simple returns should be multiplied and not added, to give cumulative returns.Introduction to Returns2m 40sAnalysing Returns or Price2mSimple Daily Returns2mTotal Returns2mCumulative Returns2m 22sSimple or Cumulative Returns2mHow to Use Jupyter Notebook?1m 54sCalculating Returns and Cumulative Returns10mFrequently Asked Questions10mFord Cumulative Returns2mLog Returns
Often a confusing concept, we have made log returns intuitive and easier for you to understand. Sometimes a price series changes drastically over a course of time. To get a clear picture of how a time series changes, you use the log prices. Calculate its returns to get the log returns.Log Prices3m 3sLog Price Graphs2mAdvantage of Log Prices2mPercentage Change in Price2mTotal Log Returns2mLog Returns2m 10sSimple or Log Returns2mDaily Log Returns2mSignificance of Log Price2mSignificance of Log Returns2mLog Prices or Daily Log Returns2mLog Returns10mCalculating Total Log Returns2mPortfolio Returns Calculations10mPortfolio Log Returns2mPortfolio Returns2mAdditional Reading10m- Components of Time SeriesBefore you implement a financial time series model, you need to understand the different components present in the time series. Learn how to identify components such as trend, mean reversion, seasonality and cyclicality using real market data.Components of Time Series1m 34sIdentifying Time Series Components2mTrending Time Series2m 26sMean Reverting Time Series1m 15sTrending or Mean Reverting2mTrending and Mean Reverting Simultaneously2mCyclical Time Series2mReason for Cyclicality2mTrending or Cyclical2mIdentifying Cyclical Industries2mSeasonal Time Series2m 27sImportance of Seasonality2mIdentifying Seasonal Pattern2mCyclical or Seasonal Time Series2mSeasonal and Trending Simultaneously2m
- Linear RegressionTake your first step in predicting stock prices! If two assets move generally in the same direction at the same time, you can use one asset’s time series to forecast the other. This method is called linear regression. Learn the basic principles of linear regression in this section.Linear Regression Fundamentals3m 16sNecessity of Linear Regression2mPredicting Output With Zero Slope2mGraph of Linear Regression2mLinear Relationship2mScatter Plot2mLinear Regression Model10mPrint Model Summary5m
- Types of ErrorsPredictions are erroneous! This section details the different types of error calculations. Depending on the linear regression model, there will be data points which lie outside the line. The distance between the fitted line and the datapoint is called error. Learn to understand errors and improve your prediction models going ahead.Types of Error Calculations3m 6sIssues With Sum of Errors2mMean Squared Error Calculation2mInferring Sum of Squared Errors2mAdvantage of Mean Squared Error2mBenefit of SSE Over SAE2mTypes of Errors10mCalculate the Error5mCalculate Mean Absolute Error5mCalculate Mean Squared Error5mError and Outliers2mCalculate Root Mean Squared Error5mRoot Mean Squared Error of a Straight Line2mWhich is a better RMSE?2mCalculate Mean Absolute Percentage Error5m
- Goodness of FitGoodness of fit is used as a criteria for measuring the fitted line’s effectiveness. This section tells us how the goodness of fit is calculated. This will help you judge whether your prediction of the asset is good enough to be converted into a trading strategy.Introduction to Goodness of Fit4m 18sWhy Goodness of Fit2mError of a Good Model2mR-Squared Value2mResidual Plot2mPattern in Residual Plot2mHigh R-Squared Value2mR-Squared10mCalculate R-Squared5mLimitations of R-Squared2mAssumptions for Linear Regression10mHighest R-Squared2mLinearity2mNot an Assumption for Linear Regression2mAutocorrelation2mResiduals2m
Multivariate Linear Regression
In this section, you will learn how multiple independent variables can be used to forecast the position of the dependent variable with a live example. You will use two stocks such as Bank of America and Citigroup to forecast the price of a third stock, J.P. Morgan. You will also look at the limitations of the linear regression approach. Depending on the relation between the assets, you can use multiple assets to predict one asset’s price.Multivariate Linear Regression1m 46sSelecting Multiple Variables in Model2mMultivariate Linear Regression Equation2mRequirement of Multivariate Linear Regression2mLagged Version of Own Time Series2mMultivariate Linear Regression Model10mOutput of Multivariate Regression Model2mLimitations and Advantages of Linear Regression2m 39sEliminating Outliers2mLinear and Non-linear Models2mLimitation of Linear Models2mAdditional Reading10m- Correlation AnalysisA widely used statistical concept in finance, correlation analysis helps in establishing a possible relationship between security prices. This in-turn helps in predicting the future price of securities. In this section, you will learn about correlation,how it is different from covariance and how to calculate covariance and correlation coefficients with their limitations.Correlation and Covariance4m 38sCalculation of Covariance and Correlation10mCovariance Value2mCorrelated Assets2mDirection of the Linear Relationship2mPortfolio Diversification2mImplementation of Correlation Coefficient10mAre Numerical Calculations Exact?10mCalculate the Correlation Coefficient5mCalculate the Rolling Correlation5m
Autocorrelation and Partial Autocorrelation
These two concepts go hand in hand while modelling time series, autocorrelation and partial autocorrelation. In this section learn about the intuition of ACF and PACF, their differences and how to plot ACF & PACF along their application.What is Autocorrelation?4m 26sAutocorrelation2mAutocorrelation Value2mStatistically Significant Values2mInterpretation of ACF plot2mForecasting Using ACF Plot2mWhat is Partial Autocorrelation?4mPartial Autocorrelation2mPACF Value2mModel Formation Using PACF Plot2mACF and PACF Plotting in Python10mSignificance of Blue Region in ACF and PACF2mACF Plot in Python5mPACF Plot in Python5mAdditional Reading10m- NoiseThe fourth component of time series, noise, can be caused by either a glitch in the recording process or a temporary deviation from the system. White noise in particular, is the noise remaining after the time series model has been optimised. The presence of white noise in the model indicates that our time series model cannot be optimised further.Noise3m 34sSimilarity of Returns and White Noise2mStationarity in White Noise2mError Plot in White Noise2mAdditional Reading10m
Autoregressive Model
Autoregressive model is based on the linear regression model which assumes past values of a time series have ability to predict future values. In this section, you will learn all about intuition of the autoregressive model, its equation and how to find the optimal lag term for an autoregressive model.Overview of Part II2m 50sAutoregressive Model - I2m 40sWhat is an Autoregressive Model?2mRepresentation of AR Model2mAutoregressive Model - II3m 9sPrerequisite for AR Model2mOrder of AR Model2mWhich AR Model to Use?2mLimitations of Using More Lag Terms2mImplement Autoregressive Model
By now, you will already be familiar with the AR model. In this section, you will learn to implement it on the financial time series along with the Python packages used for time series forecasting.Simple AR Model10mShift in Predicted Price5mAR Model of Order p10mTrain an AR Model of Order p2mAdditional Reading10m- Moving Average ModelThe second model in the family of time series models assumes that past error terms have the ability to predict future values. Learn about intuition of MA model, its equation and how to find the optimal lag term for an autoregressive model.Moving Average Model4m 47sWhat is Moving Average Model?2mPredict Price Using MA Model2mWhich MA Model to Use?2mWhat is Definition of MA(2) Model?2mSimple MA Model10mMA Model of Order q10mGenerate a Trading Signal2mAdditional Reading10m
- ARMAARMA is a more advanced model than AR and MA models. In this section, you will learn about the ARMA model, and its equation.ARMA Model2m 11sWhat is ARMA Model?2mEquation of ARMA Model2mWhich ARMA Model to Use?2mCaveats of AR, MA and ARMA10m
- StationarityA stationary time series is supposed to have constant mean and variance, irrespective of time period. The AR, MA and ARMA models require stationarity for their smooth functioning. In this section, you will learn how to convert a non-stationary financial time series to a stationary time series.Stationarity5m 19sStationarity in Kodak Prices2mStationarity and Zero Mean2mChanging Variance and Constant Mean2mSingle Order Differencing2mDefinition of Stationarity2mIdentifying Graphs of Stationarity2mIdentify the Stationary Series2mADF Test10mInterpret the Output of ADF Test2mApply the ADF Test on a Given Series5mConvert Non Stationary Series to a Stationary5mApply the ADF Test on the Difference of the Series5mAdditional Reading10m
- ARIMA ModelA forecasting model that works with non stationary time series. In this section, you will learn about the ARIMA model and its equation. This section also covers finding the optimal order for each parameter associated with the ARIMA model. Finally, you will learn to make a prediction using the ARIMA model.ARIMA Model3m 24sNeed of ARIMA Model2mOrder of Integrated2mPredict Price from Change in Price2mARMA Model on Non Stationary Data2mWhich ARIMA Model to Use?2mEquation of an ARIMA Model10mAIC and BIC10mGetting Started with ARIMA Model10mShould you Apply ARIMA?2mARIMA Model of Order (p, d, q)10mCorrect Order of ARIMA2mOptimal p for ARIMA2mAdditional Reading10mBest ARIMA Model Selection10m
- Live Trading on BlueshiftThis section will walk you through the steps involved in taking your trading strategy live. You will learn about backtesting and live trading platform, Blueshift. You will learn about code structure, various functions used to create a strategy and finally, paper or live trade on Blueshift.Uninterrupted Learning Journey with Quantra2mSection Overview2m 19sLive Trading Overview2mVectorised vs Event Driven2mProcess in Live Trading2mReal-Time Data Source2mBlueshift Code Structure2m 57sImportant API Methods10mSchedule Strategy Logic2mFetch Historical Data2mPlace Orders2mBacktest and Live Trade on Blueshift4m 5sAdditional Reading10mBlueshift Data FAQs10m
- Live Trading TemplatePaper/Live Trading ARIMA Strategy10mFAQs for Live Trading on Blueshift10m
- SARIMA ModelSARIMA or Seasonal ARIMA is one step ahead forecasting model than ARIMA. In this section, you learn about SARIMA, and why it is a must-know model in a time series forecasting. This section also covers the representation of SARIMA and how to find the optimal order of its parameters.SARIMA Model10mNeed of SARIMA Model2mOrder of m in SARIMA2mOrder of D in SARIMA2m
Introduction to Volatility
A time series is highly volatile if the price series keeps changing drastically within the time period. In this section, you will learn the definition of volatility and calculate daily and annualised volatility.Fundamentals of Volatility2m 33sDefinition of Volatility2mSteps in Volatility Calculations2mImportance of Volatility3m 12sImpact of Events on Volatility2mImpact of Recession on Volatility2mHalf-yearly Volatility2mCalculate Volatility10mData to Calculate Volatility2mWhy Log Returns While Calculating Volatility?2mResample Daily Data to Monthly Period5mCalculate the Monthly Volatility5mConvert the Monthly Volatility to Annualised Volatility5mHalf-Yearly Volatility to Annualised Volatility2m- Stylised Facts and Importance of VolatilityIn this section, you will learn the stylised facts of volatility such as volatility clustering, mean-reversion, long memory and leverage effect. You will also learn about its importance as a risk indicator and how it can be used to trade the volatility index (VIX)Stylised Facts of Volatility3m 44sSelecting Stylised Facts2mMean-reverting Behaviour of Volatility2mReturns and Volatility2mReason for Asymmetry in Volatility2mApplications of Volatility3m 23sDifferentiating Historical and Implied Volatility2mCalculating Implied Volatility2mImplied Volatility and SP5002mTrading VIX2mUsage of Volatility2m
ARCH
The volatility of the real world financial data usually changes with time. Learn how to use the ARCH model to predict the volatility of an asset using its past returns.Need for the ARCH and GARCH model1m 45sEffect of Returns on Volatility2mModel Selection: Volatility in a Range2mModel Selection: Volatility Not in a Range2mIntroduction to the ARCH Model3m 5sComponents of the ARCH Model2mReturns-Volatility Relationship2mEquation of the ARCH Model1m 25sDerivation of the ARCH Model10mIdentify the Correct ARCH Equation2mImplementation of the ARCH Model10mDefine the ARCH Model2mForecasting using the ARCH Model2mPerformance Analysis of the ARCH Model2m 42sSummarise the ARCH Model2mCompute the ARCH Volatility2mAdditional Reading10mGARCH
The ARCH model is generalised further to include the asset returns and past volatility. Learn how to use the GARCH model to predict the volatility and then use the prediction in a trading strategy.Implementation of the GARCH Model3m 31sVolatility Clustering2mComponents of the GARCH Model2mImplementation of the GARCH Model10mFinding the Optimal Lag2mPerformance Analysis of the GARCH Model1m 50sSummarise the GARCH Model2mCompute the GARCH Volatility2mTrading Strategy using the GARCH Model10mGenerate the Strategy Signal2mAdditional Reading10m- Capstone ProjectIn this section, you will undertake a capstone project on real-world data. This project will require you to apply and practice the concepts learnt throughout this course.Capstone Project: Getting Started10mProblem Statement10mFrequently Asked Questions10mTemplate Code Files2mWorking With Pickle File5mModel Solution: TSA Capstone Project10mCapstone Solution Downloadable2m
- LimitationsTime series analysis has a wide variety of applications and acceptance in the quant community, it is not perfect. In this section, you will go through the limitations inherent in time series and also ways to overcome them.Limitations of Time Series Analysis3m 51sLimitations in Methodology2mImpact of Events on Price Data2mAdditional Reading10m
- Future EnhancementsIn this section, you will look at the present scenario of time series analysis and go through a few pointers on how to improve our existing time series models.Future Enhancements3m 31sExogenous and Endogenous Variables2mIdentifying X in SARIMAX2mStylised Fact of Volatility in EGARCH2mWorking of Pairs Trading2mIdentifying Additive Trends2mApplying Exponential Models2mAdditional Reading10m
- Automate Trading Strategy Using IBridgePyAdditional Reading10mSample Strategy to Run on Interactive Brokers2m
- Run Codes Locally on Your MachineLearn to install the Python environment in your local machine.Python Installation Overview2m 18sFlow Diagram10mInstall Anaconda on Windows10mInstall Anaconda on Mac10mKnow your Current Environment2mTroubleshooting Anaconda Installation Problems10mCreating a Python Environment10mChanging Environments2mQuantra Environment2mTroubleshooting Tips For Setting Up Environment10mHow to Run Files in Downloadable Section?10mTroubleshooting For Running Files in Downloadable Section10m
- Course SummaryThis section will give a brief summary of the course and the different concepts and models you have worked on in this course. All the codes and data files are also available as a zip file in this section.Course Summary2m 52sPython Code and Data2m
- Definition and BackgroundThis section introduces the topic of statistical arbitrage and further explains the different types of statistical arbitrage strategies.Introduction of the Course2mQuantra Features and Guidance3m 48sArbitrage Strategies in Commodities3m 54sSpot the Deterministic Arbitrage2mCash and Carry Arbitrage2mWhat is Statistical Arbitrage?2mTypes of Statistical Arbitrage Strategies7mConcept of Statistical Arbitrage2mHow to Do Pairs Trading?2mIdentify the Pairs2m
Statistical Concepts in Pairs Trading
This section covers some of the most important statistical concepts which can be used to build a trading strategy. It includes topics like mean reversion, z-score, co-integration, correlation, ADF test etc. In addition to it, it also explains how and when pairing in commodities is done.Mean Reversion and Z-Score Overview2m 37sMean Reversion Principle2mZ-Score2mWhat is Cointegration?1m 40sHow to Use Jupyter Notebook?1m 54sCointegration Vs. Correlation10mMean Reversion Principle2mDifference Between Correlation and Co-integration2mHow to Select Pairs?3m 8sWhen to Pair Stocks?2mKnow the ADF test10mProperties of Time Series2m- Pairs Trading Strategy in ExcelThis section explains the concept of Linear Regression and gives the Excel function for the same. It also provides knowledge about generating buy/sell signals for pairs trading.Frequently Asked Questions10mCheck for Cointegration of Pairs2m 47sExcel Function for Linear Regression2mPurpose of Linear regression2mGenerating Buy/Sell Signals: I4m 11sSignal for Pairs Trading2mGenerating Buy/Sell Signals: II3m 53sWhat is Drawdown?2m
- Pairs Trading Strategy in PythonThis section, as the title suggests, demonstrates the implementation of the Pairs Trading strategy in Python. You will learn how to code the strategy and calculate various parameters like z-score, status, buy price, sell price, MTM and PnL.Import Libraries and Initialise Variables4m 40sDefine Functions5m 32sExecute Pairs Trading Strategy4m 14sInterpretation of Critical Values of ADF Test2mPairs Trading Strategy in Python10mGetting Started with Interactive Exercise5mFetch Data5mRun ADF Test5mCalculate Z-score5mGenerate Trading Signals5mCalculate Status5mCalculate Mark-to-Market (MTM)5mCalculate Strategy PnL5m
- Live Trading on BlueshiftThis section will walk you through the steps involved in taking your trading strategy live. You will learn about backtesting and live trading platform, Blueshift. You will learn about code structure, various functions used to create a strategy and finally, paper or live trade on Blueshift.Uninterrupted Learning Journey with Quantra2mSection Overview2m 19sLive Trading Overview2m 41sVectorised vs Event Driven2mProcess in Live Trading2mReal-Time Data Source2mBlueshift Code Structure2m 57sImportant API Methods10mSchedule Strategy Logic2mFetch Historical Data2mPlace Orders2mBacktest and Live Trade on Blueshift4m 5sAdditional Reading10mBlueshift Data FAQs10m
- Live Trading TemplateBlueshift Live Trading TemplatePaper/Live Trading Pairs Strategy10mFAQs for Live Trading on Blueshift10m
- Managing Risks in Stat ArbThis section provides insights into the various types of risks involved in statistical arbitrage strategies and ways to mitigate them.Risks in Statistical Arbitrage3mStock Specific Risk2mExecution Risk2mModel Affecting the Market2mSystematic Risk2mIdentify Pairs and Stop Loss7mAdditional Reading on Loss Minimisation2mCourse Summary1m 31s
- Run Codes Locally on Your MachineLearn to install the Python environment in your local machine.Python Installation Overview2m 18sFlow Diagram10mInstall Anaconda on Windows10mInstall Anaconda on Mac10mKnow your Current Environment2mTroubleshooting Anaconda Installation Problems10mCreating a Python Environment10mChanging Environments2mQuantra Environment2mTroubleshooting Tips For Setting Up Environment10mHow to Run Files in Downloadable Section?10mTroubleshooting For Running Files in Downloadable Section10m
- Downloadable ResourcesThis consists of a downloadable e-book, Excel models and Python codes.Data, Python Code and Spreadsheet Files2m
about author




Why quantra®?
- More in Less Time
Gain more in less time
- Expert Faculty
Get taught by practitioners
- Self-paced
Learn at your own pace
- Data & Strategy Models
Get data & strategy models to practice on your own
Faqs
- Are there any webinars, live or classroom sessions available in the course?
No, there are no live or classroom sessions in the course. You can ask your queries on community and get responses from fellow learners and faculty members
- Is there any support available after I purchase the course?
Yes, you can ask your queries related to the course on the community: https://quantra.quantinsti.com/community
- What are the system requirements to do this course?
Fast-speed internet connection and a browser application is required for this course. For the best experience, use Chrome.
- What is the admission criteria?
There is no admission criterion. You are recommended to go through the prerequisites section, be aware of skill sets gained and to learn the most from the course.
- Is there a refund available?
We respect your time, and hence, we offer concise but effective short-term courses created under professional guidance. We try to offer the most value within the shortest time. There are a few courses on Quantra which are free of cost. Please check the price of the course before enrolling in it. Once a purchase is made, we offer complete course content. For paid courses, we follow a 'no refund' policy.
- Is the course downloadable?
Some of the course material is downloadable such as Python notebooks with strategy codes. We also guide you to use these codes on your own system for you to practice further.
- Can the Python strategies provided in the course be used immediately for trading?
We focus on teaching about quantitative and machine learning techniques and how learners can use them for developing their own strategies. You may or may not be able to directly use them in your own system. Please do note that we are not advising or offering any trading/investment services. The strategies are used for learning & understanding purposes and we do not take any responsibility for the performance or any profit or losses that using these techniques results in.
- Are you using real time Stock market data in the course?
No. We do not take examples from 'real time data', but you shall be learning to code through historical data. Please do note that there is a section at the end that will guide you on how to automate for real time live trading. You can get more detailed learning on how to automate trading strategies through our free course, 'Automated trading with IBridgePy using Interactive Brokers Platform'.
- Will I be getting a certificate post the completion of the programme?
Yes, you will get a certificate for each course separately within a few hours of completion of the course. The certificates are downloadable from your account tab "My Certificates".
- What does "lifetime access" mean?
Lifetime access means that once you enroll in the course, you will have unlimited access to all course materials, including videos, resources, readings, and other learning materials for as long as the course remains available online. There are no time limits or expiration dates on your access, allowing you to learn at your own pace and revisit the content whenever you need it, even after you've completed the course. It's important to note that "lifetime" refers to the lifetime of the course itself—if the platform or course is discontinued for any reason, we will inform you in advance. This will allow you enough time to download or access any course materials you need for future use.
- Is Python an essential skill for automated trading for beginners?
Python is not strictly essential for beginners in automated trading, but it is highly recommended. Here’s why:
Ease of Learning: Python has a beginner-friendly syntax, making it accessible even for those new to programming.
Versatility: Python is widely used in the finance industry for tasks like backtesting, data analysis, and building trading algorithms. Libraries like Pandas, NumPy, and TA-Lib make it easy to analyse financial data
Extensive Community Support: Python's popularity means a vast amount of tutorials, forums, and resources are available for troubleshooting and learning.
Integration with Broker APIs: Many brokers and trading platforms offer APIs with Python support, enabling seamless integration for order execution and real-time data analysis.