Backtesting Hundreds of Stocks at Once, in Python

preview_player
Показать описание
Thanks for watching this part three of the backtesting tutorial.

Link to the Google Colab Notebook that is featured in this video:

Submit a strategy for me to backtest in a future video:

Simply save a copy into your own Google account

If you missed parts 1 and 2:

Part 1:

Part 2:

As always, nothing here is investment advice and I am not an investment advisor. Additionally, there is no guarantee of accuracy to the code presented.
Рекомендации по теме
Комментарии
Автор

It might be a small group watching these coding videos as you say but I think anyone who is watching them greatly appreciates you sharing all the details of the backtesting strategy you use. Personally I'm hoping for a part 4 which covers the aggregation of all results like you demonstrate in your backtest videos, including the trade and drawdown histograms. I think the trade histogram showing the profitability of multiple random selections of trades is a particularly interesting and unique feature that I've not seen used elsewhere. Please keep up the great work!

kevinmckinney
Автор

Come on man you're doing gods work, sincerely, please post more frequently

louiss
Автор

Yes! I’ve been excited for your next video. This is great!

keltonpreece
Автор

First comment, I'm here after watching a great number of your videos and you're just so so good man. Love it. Keep it up, I'll be following along x

samuelbridges
Автор

amazing video, looking forward ot the next one possibly explaining running simulations, data visualization with account balances, etc... that you have up on your other videos

vi-uujp
Автор

Last time I asked when will the next backtesting tutorial would be posted you replied and posted it that same day.


Trying my luck again!!!

I love your videos, keep it up.

oddskid
Автор

Thanks for this demo. I'm a novice python coder but really interested in portfolio backtesting. Your Playlist of videos really gave me the confidence to design my own tests with the ultimate goal to go live

patrickbaboon
Автор

Wonderful work you are doing here. Thanks for the education and the starter code in colab! Most grateful!

haedike
Автор

This was a great help to me. You have motivated me to finally learn python. One issue I had with the notebook was the section where you are spliting all the symbol csvs in the folder that was created locally. For some reason I was getting the folder path name in the dict_keys output. I was able to fix this by using split('\\') instead of split('/'). After that everything work for me. Thanks again now I can go through and really diesect what each line of code is doing.

adventurebay
Автор

This is an incredible demo. I wish more "backtesting" channels are as high quality as this one. This is so good.
As an idea of your next video, would you be able to demo the monte carlo on a specific strategy and plot out the gain bell curve to check for statistical significance as in your previous videos?

KentSo
Автор

Hi, thanks for sharing, is there modules/libraries to use this backtesting tech so that it can be used to scan on active data? The "Powerful swing or scalp strategy tuned for minimal drawdown and consistent results" is great, I did it in pine script but there are so few occurrences that it would need an extraodinary amount of alerts/seup to get enough trades to be worth it.

rhino
Автор

Fascinating. You've inspired me to start a Google Collab and write up backtests based on my own ideas & ideas I've found through the grapevine. Would love to hear your thoughts on your favorite/most profitable strategies that've worked for you based on your backtests. Obviously would be open to paying/donating for that content if it helps you.

victorsblog
Автор

Thanks a lot for putting in all the effort in both the video and the Colab book! Really interesting learing from these particular video's and already trying to give it a go myself:).
I have a suggestion which i would like to try out myself, but I am not sure on my thought process: If I would sort the trading results on the datetime index, would that provide me with the ability to count the maximum drawdown and equity curve? I am thinking about your backtest for the MACD + RSI + STOCH video in which you showed a really stable equity curve, however thinking that the datetime of those trades have a significant influence on that stable curve. You did adjust for this in later video's I think.
Anyway thanks a lot again! Really interesting stuff to work with!!

stanverhoeven
Автор

Thanks a lot!!
Awesome content, miles ahead what others related channels offer
I hope youtube notice and rewards you accordingly
Cheers!

jm
Автор

could you do a backtest XAUUSD on the OANDA server using multiple ema 20 on (1-hour tf, 4-hour tf and daily). the entry rule is when the price is emerging up from the bottom of 4H ema and the 1H ema < 4H ema < daily (the short rule is the opposite). the SL is the last low or the 1.6 ATR. The TP is the last high of the 30-minute candle. when the order is on 1R, cut half of the order size. Thank you.

the other thing that I am curious about is, what kind of indicator do you suggest to determine the trend of the market (trending or sideways), it will really help if you can identify and switch the strategy mode.

Muhammadxuxix
Автор

Great video serie. Thanks for sharing it. By the way, you should consider the spread as a cost...😊

jdaniele
Автор

Bravo! Thank you very much! I want to ask you, can you talk about survivorship bias and how we can get or workaround better data? I read somewhere that there are a paper saying that, for data with survivor bias it can increase about 7-10 % the results, per year. Anyway, thanks again, your videos are the best!

alxcancado
Автор

Hey man, please include part 3 somewhere in the posted title. Will help especially in future when these videos get buried by the rest of your new uploads.

dingleberry
Автор

Have you considered doing backtests on the Indices, Metals, or Major Forex Pairs?

ConfusedKev
Автор

Fantastic stuff! Curious how you can also getting entries on specific dates like the end of month as well!

VOLightPortal