Not able to correctly replicate strategy in Tradestation (multiple datastreams )

115 views
Skip to first unread message

Pat

unread,
Sep 20, 2022, 3:33:24 AM9/20/22
to Adaptrade Builder
Maybe someone has had this issue too and has an idea or solution to it...

My process is as follows:

(1) In Tradestation I load 3 datastreams (@NQ, @ES, $ADNDD) into the same chart (Time Zone = Local, meaning they are synchronized) and export them by individually saving the data from the data-window  into 3 separate .csv files.

(2) In AB I load the 3 data (1 primary, 2 secondaries) and build a strategy. I limit the trading-window by setting the Trade entry times to e.g. 14:30 - 20:30. 

(3) In Tradestation I create a new strategy and paste the respective Strategy Code from AB. Then I add the strategy to the very same chart from which I exported the 3 datastreams. 

The problem is that the TS strategy results - most of the time - don't match the AB results at all (sometimes the differences are less stark, apparently depending on the individual strategy settings).

I couldn't find out what I'm getting wrong, any ideas and suggestions welcome, thanks.


Mike Bryant

unread,
Sep 20, 2022, 1:51:23 PM9/20/22
to adaptrad...@googlegroups.com

Problems like that with multiple data series can be difficult to diagnose because of all the different possible sources of discrepancy. Have you read through the possible sources of discrepancy discussed in my FAQ item on this topic? If not, it’s in the user’s guide and online under the Support link here (or you can find the link on the Builder main page). Many of the items discussed there could apply to any of the data series you’re using. The other possibility is that it’s a matter of alignment of the data; i.e., the bars in Builder don’t correspond to each other the same way as in TradeStation. Based on your description, that should not be a problem, but I would double-check the price data in Builder using the View Data button on the Build Symbols window to make sure the data in Builder are the same as in TS. As long as all the data series are the same as in TS, I would look for one of the issues noted in the FAQ. With three data series, it may not take much of a difference to throw off the trades, causing a discrepancy, particularly if you have a large number of trades and/or complicated trading logic, such as a neural network.

 

Mike Bryant

Adaptrade Software

Pat

unread,
Sep 27, 2022, 1:13:03 AM9/27/22
to Adaptrade Builder
I have indeed gone through the user guide in detail and analyzed the synchronizity of data. 

I finally came to realize that it's not a problem of multiple datastreams but of THIGHT STOPS AND/OR TARGETS that are being applied! Some strategies chose to set stops and targets so thight that they can be triggered within the same bar. This, in turn, leads to unrealistic / over-optimistic performance because AB can't consider intrabar-resolution.

How to optimally deal with this? Possible solutions imho would be to a) increase minimum levels for targets and stops, b) just use either fixed target OR stop, c) lower bar-resolution while maintaining the same stop levels.

Working on it, ideas / experiences welcome... 

Reply all
Reply to author
Forward
0 new messages