TradersMeetup.net
DisclaimerDisclaimer: Neither TradersMeetup.net nor its organizers, hosts or presenters are licensed financial advisors, registered investment advisors, registered broker-dealer nor FINRA | SIPC | NFA-member firm. In accordance to the policies of TradersMeetup.net, this presentation does not provide investment or financial advice or make investment recommendations. TradersMeetup.net is not in the business of transacting trades, nor does TradersMeetup.net agree to direct your brokerage accounts or give trading advice tailored to your particular situation. The content of today’s presentation does not constitutes a solicitation, recommendation, promotion or endorsement of any particular security, other investment product, transaction or investment.
Trading Futures, Options on Futures, and retail off-exchange foreign currency transactions involves substantial risk of loss and is not suitable for all investors. You should carefully consider whether trading is suitable for you in light of your circumstances, knowledge, and financial resources. You may lose all or more of your initial investment. Opinions, market data, and recommendations are subject to change at any time.
All rights reserved. This Material may not be reproduced or distributed, in whole or in part, any other reproduction in whatever form and by whatever media, is expressly prohibited without the prior written consent of TradersMeetup.
No Soliciting. No Recording. No Photography.
AGENDA• What is retail-based algorithmic trading
• Why do traders use this format
• Types of Trading Strategies
• Life Cycle: setup, planning, research, testing, portfolio diversification, etc.
• Idea Modeling & Strategy Review
• Risk Management, Position Sizing
• Backtesting, Walk-forward testing, incubation
• Tools, software, resources
Before we begin, consider . . .
What is Algorithmic Trading?
• Employing computers to follow a set of instructions (an algorithm) to place trades for profit.
• Defined sets of rules can be based on timing, price, quantity or any mathematical model.
• Define the ENTRY and EXIT signals.
Simple Example using 2 moving average:
• Buy 50 shares of a stock when its 50-day moving average goes above the 200-day moving average.
• Sell shares of the stock when its 50-day
moving average goes below the 200-day
moving average.
WHY TO PEOPLE USE IT ?
• Trades execute at best possible pricing
• Instant and accurate order placement
• Reduced risk of manual errors
• Can be backtested
• Reduce emotional/psychological factors that cause mistakes
Creates a systematic approach to trading whereby:
Types of Trading Strategies
• Trend-following Strategies
• Arbitrage Opportunities
• Index Fund Rebalancing
• Mathematical Model Based Strategies
• Trading Range (mean reversion)
There are an many different trading strategies to cater to what psychologically works for you.
• Volume Weighted Average Price (VWAP)
• Time Weighted Average Price (TWAP)
• Percentage of Volume (POV)
• Implementation Shortfall
• Sniffing Algos
• And many others!
What do you need
• Computer programming knowledge (or hire a programmer or leverage premade software
• Trading platform
• Network connectivity
• Market data feeds
• Historical data for backtesting
To convert your strategy into computer code that can place orders you need:
Life CycleThis represents one of just many methods by which algo trading cycles
Initiation of an Idea, Research
IDEA & Quant. Analysis
Live Trading
PRODUCTION
Back Testing & Optimization, Forward Testing, Incubation
BACK TEST
Automation
AUTOMATION
Design and Development
Strategy Development
Idea Modeling
• Keep it simple
• Define your approach to time (Y,M,D,H,M,S,Ticks, other)
• Understand your Signal(s)
• What happens when your event takes place?
• Probability indicator
Risk Management
• Stop Loss (specific threshold or formula)• Profit Target (specific threshold formula)
Method you use can be dependent upon strategy you apply. (e.g. applying a fixed Stop Loss to a Mean Reversion strategy may reduce overall performance)
Position SizingPosition sizing is a technique that consists of adjusting the size or the number of shares/contracts of a position before or after initiating a buy or a short trading order.
Position sizing is very important and if applied correctly, it can dramatically improve your strategy performance and help you avoid ruin.
Some Position Sizing Techniques:
• Fixed Dollar Amount
• Fixed Risk per Trade
• Volatility based Position Sizing
• Kelly Criterion
• Averaging Down
• Optimizing Position Sizing variables
• others...
Backtesting, Walk Forward TestingBacktesting is carried out by exposing your particular strategy algorithm to a stream of historical financial data, which leads to a set of trading signals.
Backtesting should include all trading costs.
Walk Forward Testing: In Sample / Out of Sample
No backtest is perfect nor should be considered an indicator of what your future results would be.
Equity Curve
Draw Down
Monte Carlo
Variance Testing
Equity Bands
Seasonality
Noise Test
Fitness Function: Profit & Loss, Sharpe, Sortino, DrawDown, T-Test, etc.
Equity CurveStrategy Performance
Walk Forward TestingIn Sample / Out of Sample Data
Monte Carlo
Backtesting and BiasBacktesting is not perfect and prone to bias
• Optimization Bias - over optimization, curve fitting until strategy is ‘attractive’
• Look-Ahead Bias - due to tech. Bugs or parameter calculation• Survivorship Bias - testing on today’s stocks and not prior stocks that have
been delisted (one example)• Psychological Tolerance Bias - discretionary judgement to algo trade.• Host of other bias’ to consider.
Example Code
Example Chart
Example StrategyPerformance Report
Platforms
• TradeStation • MultiCharts• NinjaTrader• Trading Technologies• Cloud Based• Hosted Platforms• Many others!!• Or… write your own!
Reference
TradeStation Best Practices
https://clientcenter.tradestation.com/download/BestPractices.aspx
Q&A