Australian (ASX) Stock Market Forum

Dump it Here

Interesting how we all get slightly different results from the same code and source.
Amibroker with original code + Norgate Platinum
1/7/2020 - 30/12/2020
Not too shabby.

@silent1a I have to agree with @dpong - your backtest results aren't too shabby. Thank you for doing a backtest & supplying additional results.

What we need now
Someone to make amendments to improve the returns. I'm sure "dpong" will address the high drawdowns with the U.S. markets. @Warr87 suggested the (CCI) Strategy suffers in a few different time periods, this needs to be addressed.

The Commodity Channel Index (CCI)
The (CCI) momentum oscillator identifies cyclical trends. The issue that most traders have using the CCI momentum oscillator is that they believe it displays "excessive lag" making it an unreliable generator of buy & sell signals - well that's true to a certain extent but filtering can alleviate false signals to some degree.

Skate.
 
Something is wrong when CCIFast is trying to be slow.
Did a quick optimisation of CCIFast and CCISlow between 2~20 weeks.

I may look into changing the other parameters or adding other filters.

Data Source: Norgate Platinum
Date range: 1/01/2010 - 30/12/2020
Watchlist: All Ords Current and Past (All Ords at time of purchase)
Pad and Align: using XAO.au
Timeframe: Weekly
1610511493238.png
CAR/MDD Graph
1610511169883.png
 
Last edited:
I confess Mr @Skate that coding is over my head, but I am intrigued/slash impressed with the process you and the other chaps are able to formulate to gain an advantage.

I wonder, given the massive amount of data you have presented over the last couple of years, whether the Thread may eventually morph into several Sub-Threads which feed off the Original?

That in itself might be an "Indexing" nightmare, but I suspect you could come up with an appropriate coding system for that as well;) :wheniwasaboy:

Either way, well done on what may become an ASF "War and Peace":smug:
 
@silent1a, @dpong code snippet was for a "Daily Strategy" not weekly - this could be the issue.

Update (2).png

Daily CCI Strategy
Originally the code snippet that @dpong posted was for a "Daily Strategy" so I'm attaching a Daily Strategy for review. Make sure you change the periodicity to daily before running a backtest.

Skate.
 

Attachments

  • Skate's Modified dpong CCI Daily Strategy.afl
    11.5 KB · Views: 30
Does well enough in the latter half of the decade but badly in the first half.

Strategy: Skate's dpong CCI DAILY Modified Strategy
Data Source: Norgate Platinum
Date range: 1/01/2010 - 30/12/2020 in 1 year intervals
Watchlist: All Ords Current and Past (All Ords at time of purchase)
Pad and Align: using XAO.au
Timeframe: Daily

1610615919969.png

I may create my own daily strategy for when I have enough time to trade it.
 
Does well enough in the latter half of the decade but badly in the first half.

@silent1a, thank you for doing a backtest on the "CCI Daily Strategy". The strategy couldn't handle 2011 (my benchmark) so it's not tradeable in its current format. A " CCI Strategy" is a momentum strategy, meaning it works well in a bull market & not so well in others. The strategy has been uploaded so others can experience basic coding first hand & hopefully encourages others to do a bit of research.

Skate.
 
Isn't it weird that my implementation, so basically mostly the same components bought at a different time managed to get a +2pc on the same week?
One of us could be doing a recording mistake , the only difference i am aware is flc that i got out of as i purchased initially much higher and so reached the %SL and was replaced by a different packet.
Have all a great weekend
 
Isn't it weird that my implementation, so basically mostly the same components bought at a different time managed to get a +2pc on the same week?
One of us could be doing a recording mistake , the only difference i am aware is flc that i got out of as i purchased initially much higher and so reached the %SL and was replaced by a different packet.
Have all a great weekend

@qldfrog it's just a timing issue, the HappyCat Strategy has only been running for a heartbeat. Monte Carlo simulation confirms trading the same strategy at different times renders different results.

Skate.
 
Hi folks,
I am testing weekly strategy with calculations on daily bars. Strategy results significantly change with the day of week (Mon-Fri) when trading is done - i.e. Trading on Mondays results in double returns in comparison to trading on Tuesdays. Did you experience the same behaviour? I consider trading such strategy quite risky.
Will be glad for any opinion!
 
Isn't it weird that my implementation, so basically mostly the same components bought at a different time managed to get a +2pc on the same week?
One of us could be doing a recording mistake , the only difference i am aware is flc that i got out of as i purchased initially much higher and so reached the %SL and was replaced by a different packet.
Have all a great weekend

Overall mine is tracking Skate's result, just a fraction of a percent higher.
 
"Over time your views will change, soon realising that the secret to trading successfully is "staying in the game" & not necessarily making a lot of money quickly but compounding it over time." - Skate, this may be the most important sentence any trader can read - well said.

Our views do change over time
With more trades under your belt, you tend to accumulate a sizable amount of "closed profits". If you were lucky to trade the 2019 calendar year you would have made a bucket load of money. Trading in 2020 (calendar year) started well only to experience a horrendous period not only for traders but for the whole human race. The Covid-19 flash crash gave traders a unique opportunity (chaos & volatility). Some traders were shell shocked while others took advantage of the situation. 2020 was my best trading year by far & I suspect it's the same for most system traders. With two great years under your belt, what do you do with the closed profits?

How do I re-invest "closed" profits?
This could be an issue for some & it certainly was for me. I'll answer this in the next few posts.

Skate.
 
How do I re-invest "closed" profits?

Traders love profit it's the dopamine that keeps us trading
Some traders have a hard time knowing that there are two types of profits. There are "Closed" profits & there are "Open" profits.

Profits are easy to distinguish
"Open Profits" belong to the markets whereas "Closed Profits" belongs to you. When you accept this fact, trading becomes much easier.

Skate.
 
How do I re-invest profits?
This could be an issue for some & it certainly was for me. I'll answer this in the next few posts.

How do I handle trading investment profits?
Let's start with profits from a "set & forget" type of investments that being (Investing in "LIC's & Buy & Hold" type portfolios). With investments rather than trading, it's an easy question for me to answer - "Dividend Reinvestment".

DRP
A dividend reinvestment plan merely is reinvesting the dividends, by automatically buying additional shares with the dividend, rather than taking the cash. The downside is that capital gains tax (CGT) still applies, so if you participate in a dividend reinvestment plan, it will be treated as if you have received a cash dividend. Well, that's life!

Skate.
 
How do I re-invest "closed" profits?

Over time your views will change
Certainly, I have changed my views on how I now handle "closed profits". Once I use to re-balance my bet size using closed profits. Even after increasing my bet size, I would go on to increase the number of shares in my portfolio. Both methods have been kind to me in the past but as with all things, you start to look for alternative ways to re-invest those closed profits for a better advantage. The "closed profits" gave me a perfect opportunity to start trading strategies that have been waiting patiently for their chance to prove themselves trading alongside the big boys.

These profits allowed me to "trade live" two small accounts
The Action Strategy & the HappyCat Strategy. Looking back it's a pity I stopped trading the Action Strategy in the "Dump it here" thread as it's still outperforming most of my other trading strategies. I take comfort knowing that its replacement (the HappyCat Strategy) is purring along.

Closed profits are still flowing in
These extra funds will now allow me to start trading another new strategy - "The Shield Strategy"

Skate.
 
"The Shield Strategy"
Trading this strategy will be a little different to most in the past. I'll be using closed profits to build this strategy over time. I have $35k of closed profits that will give me 7 new positions to kick it off with. Additional closed profits will be used to build the strategy into a 20 position portfolio. "The Shield Strategy" will be complete when it turns into a $100k Portfolio (20 Positions X $5k bets).
Stocks Fall as Economic Pain Deepens, Rally Runs Out of Gas
Wall Street closed out its first losing week in three with another drop on Friday after reports showed the pandemic is deepening the hole for the economy, as Washington prepares to throw it another lifeline - discouraging data on the economy. The S&P 500 fell 1.5% over the week.

"The Shield Strategy" starts on Monday
After reading @bigdog post today I know I will need some luck starting out.

Skate.
 
Top