Back to Browse

Backtesting Scot1and’s Slingshot Trading Strategy in Python

2.8K views
Dec 31, 2021
43:33

We backtest @scot1andT's slingshot strategy that helped him generate multiple triple-digit annual returns. Learn how to #backtest using #python and #pandas. We cover importing the applicable python libraries, web scrap the Nasdaq current constituents, resample minute bars into hourly and daily bars while correcting timezone issues, and then analyze the results by creating a DataFrame and determining the strategy edge. 👍 Subscribe for more: https://bit.ly/3lLybeP 👉 Follow along: https://analyzingalpha.com/slingshot-trading-strategy 00:00 Introduction 00:52 Update Python Path 01:32 Slingshot Setup Overview 02:47 Get Imports 03:17 Set Backtest Timeframe 03:47 Create Universe 04:07 Web Scrape QQQ from Invesco 06:10 Get Bar Data 07:42 Analyze Timeseries Timezone 09:10 Add Timezone 10:47 Create Indicators 12:27 Resample Timeframes 13:27 Create Hourly Bars Using pd.Grouper 16:49 Create Daily Bars 20:42 Merge Pandas Timeseries Data 21:12 Align Start and End Times 23:42 Merge Hourly & Daily Timeframes 24:12 Fill Missing Data 25:19 Create Slingshot Signal 27:42 Verify Entry Signal 29:00 Analyze Results 30:02 Loop Through Risk-Reward 31:10 Loop Through Tickers 32:02 Loop Through Bars 37:52 Create Results Dataframe 39:30 Create Summary Statistics --- Videos are intended strictly for information, education, and entertainment purposes. Do not base any investment decisions based upon these materials. Please read the disclaimer: https://analyzingalpha.com/disclaimer ---

Download

1 formats

Video Formats

360pmp457.5 MB

Right-click 'Download' and select 'Save Link As' if the file opens in a new tab.

Backtesting Scot1and’s Slingshot Trading Strategy in Python | NatokHD