Great Video! Can you simultaneously do a backtesting on all 4 symbols like for example EURUSD and SPUSD so if I buy on SP500 on 2011-01-07 and sell on 2011-01- 10 then in the next buy this program will recheck the opportunity in EURUSD and SPUSD and automatically matches the buying signal and then buy that stock after 2011-01-10 in this way we can have a full return on investment 😀
@@thetradingmuse1384 Yes but if the strategy implies moving averages with n period, the strategy will start at n period after the start date. The buy and hold strategy will start at the start date. That's a problem.
I noticed that if you have a position and meets the buy criteria again, the system will sell off the current position first (decided by system) and buy again. Is the observation of the behavior correct?
In this strategy if SMA(short) crosses over SMA(long) then a buy signal is produced. This does not happen again unless the reverse happens first, SMA(long) crosses over SMA(short). So because you cannot get a buy signal when you already bought, the system keeps the position until the sell signal is produced, SMA(long) crosses over SMA(short).
Heatmap stores the heatmap, the calculated values for different combinations of the parameters. \ just means the statement continues on the following line.
You should post links for getting your code, like most do?
Great Video! Can you simultaneously do a backtesting on all 4 symbols
like for example EURUSD and SPUSD
so if I buy on SP500 on 2011-01-07 and sell on 2011-01- 10 then in the next buy this program will recheck the opportunity in EURUSD and SPUSD and automatically matches the buying signal and then buy that stock after 2011-01-10
in this way we can have a full return on investment
😀
How to make sure that Buy & Hold Return strategy and your strategy start at the same time?
You set the start and end date for the data, and use the same data set for both strategies.
@@thetradingmuse1384 Yes but if the strategy implies moving averages with n period, the strategy will start at n period after the start date. The buy and hold strategy will start at the start date. That's a problem.
This is using small data, what do I do if I want to load large data(10gb) in chunks?
I noticed that if you have a position and meets the buy criteria again, the system will sell off the current position first (decided by system) and buy again. Is the observation of the behavior correct?
In this strategy if SMA(short) crosses over SMA(long) then a buy signal is produced. This does not happen again unless the reverse happens first, SMA(long) crosses over SMA(short). So because you cannot get a buy signal when you already bought, the system keeps the position until the sell signal is produced, SMA(long) crosses over SMA(short).
Nice!! I don't get what do you store in heatmap variable at line 51? What is that \ at the end? I am new in python
Heatmap stores the heatmap, the calculated values for different combinations of the parameters. \ just means the statement continues on the following line.
Merhaba python ile bot kodlama ve bactest yapabilmeyi profesyonel bir kanaldan öğrenmek istiyorum udemy üzerinden vs öneride bulunabilir misiniz?
udemy'de "python backtesting" diye aratırsanız birkaç ders çıkıyor. İnceleyebilirsiniz, ben kendim bakmadım.
@@thetradingmuse1384 sizin bu şekilde bir eğitim seriniz olacak mı?
How to use backtesting.py without talib?
You may want to check out kernc.github.io/backtesting.py/ for the examples. You can use other libraries too, talib is written in C and is fast.
@@thetradingmuse1384 The backtesting.py document is weak. There are a few examples.
Turk musun aga? :) aksanin oyle gibi
%100
bunu yazmaya gelmiştim hahaha