Petersfield, UK
Posts: 2 since Sep 2015
Thanks Given: 0
Thanks Received: 0
|
Hello fellow traders,
It's been a long time since I logged into this site, which coincides with the amount of time I have not been trading. With that said, I'm ready to dive back in and looking at a purely automated approach.
I have a couple of profitable strategies in the S&P but want to look to increase the products I trade to provide better portfolio diversification. I'm in the process of taking the Larry Williams concept of TDW to put into a spreadsheet for all symbols, I've written a basic buy on open and exit on close strategy to run across various products and have created custom sessions for the main products so that they only trade the pit hours.
As Tradestation does not allow a simple buy on open I've had to use the previous day to trigger the buy on open of the next bar. One of the issues I've seen is that in a few symbols it's trading on 2 consecutive days which is throwing my results out, I'm using the exchange time session of each and the open of the next day is, absolutely, the next day. Has anybody come across this before and can point me to the error of my ways?
Symbols like E-Mini, Crude and Gold are good, Wheat, Bonds and Copper are trading on 2 consecutive days.
The code for the strategy is very simple which allows me to run the optimization for 5 days of the week easily.
inputs: DoW(1);
If DayOfWeek(date) = DoW
then buy next bar at open;
Setexitonclose;
I have an example of Wheat with a custom session of 08:30 - 13:15 with a DoW value of 2 meaning a buy at open on Wednesday only (so I thought!) which also trades on Thursday.
Thanks for a great forum everyone
|