Home › Forums › Trading System Mentor Course Community › AmiBroker and Data Setup › WTT selection bias code
- This topic is empty.
-
AuthorPosts
-
January 25, 2019 at 9:55 pm #101891AnonymousInactive
Hi,
I am trying to run the WTT system and have done some backtesting but don´t have the selection bias code which think can improve a lot the results
Think that I read somewhere that the code was shared on the forum by Julian but went through all of his posts and couldn´t find it
Would someone be able to share that code?
Thanks a lot,
Roberto
S
January 28, 2019 at 9:16 pm #109567Stephen JamesMemberI’ve emailed you the template Roberto
January 29, 2019 at 10:50 am #109570LeeDanelloParticipantHi Craig…a little confused on the selection bias front when it comes to trend following systems. In the **Eliminating Selection Bias** thread, within the AmiBroker Coding and AFL category, Nick intimated a preference towards using “MCS with trend systems because of start date dependency”.
Given your response to Roberto, could I please trouble you to clarify the preferred approach (if in fact you are now using specific selection bias code for trend systems as opposed to/in addition to MCS)?
If selection bias code is now applicable, could I also trouble you for a copy of same as it applies to trend following systems.
Thanks
LeeJanuary 29, 2019 at 3:19 pm #109573TimothyStricklandMemberAre trending systems subject to heavy selection bias? I was of the understanding it wasn’t as big of an impact (based on how you traded). I believe selection bias becomes a serious problem in shorter term systems, correct me if I’m wrong. I’m still learning
January 29, 2019 at 9:42 pm #109574Nick RadgeKeymasterTim / Lee,
Start Date bias is the lesser of the two evils and will occur in any type of investment in any asset class.
Consider a buy and hold investor using an index ETF. Person #1 buys in June 2007. Person #2 buys in March 2009.
Even though they hold the same asset they have vastly different returns and vastly different experiences. This is start date bias.
When running a trend system you are better off removing selection bias as it will then remove any discretionary decisions in the future, and in turn you will have a higher level of confidence.
My only suggestion would be when testing is to start at different intervals, i.e. Jan 1st, Feb 1st, Mar 1st and see how it impacts on results.
Then assess those results on how the market was at hat time, i.e. as per above. You need to consider the system performance had you started June 2007 vs March 2009 because the former will more than likely show a lower return because it sat in cash.
I would use the CBT code to remove Selection Bias and also remove the need to take discretionary decisions in the future.
Note – if you intend to implement the portfolio based on a specific start date, you will need to buy the existing open positions so the realtime account will match the backtest going forward.
January 30, 2019 at 12:27 pm #109578JulianCohenParticipantNick Radge wrote:Tim / Lee,I would use the CBT code to remove Selection Bias and also remove the need to take discretionary decisions in the future.
Note – if you intend to implement the portfolio based on a specific start date, you will need to buy the existing open positions so the realtime account will match the backtest going forward.
When I implemented my WTT with the selection bias code I tested it over a variety of different dates to ensure that the system itself was intrinsically robust.
Then I chose a start date, basically I looked back to see what positions were showing as open in the backtest and looked to see which was the earliest position purchased. I don’t actually think it matters how you decide on the start date, but you MUST always run your operational backtest each week from that date.
I didn’t buy all the positions immediately. I looked to see which ones had some momentum to them and placed stop entry orders slightly above the market. My intention was to buy the positions that had some momentum behind them. This is, after all, a long term system, so actually return results and backtest return results will probably differ for a while. The main thing is that the system always shows the same positions as you are holding, although the return might differ a little, due to the start date bias.
My system is still holding two stocks, even though it hasn’t generated any new positions due to the Index Filter, but those stocks haven’t fallen enough to close out. maybe they will be big earners when the markets pick up again.
-
AuthorPosts
- You must be logged in to reply to this topic.