As others have said, "Average return is just one statistic". When trading, losses hit harder than wins. Go up 50% then down 50% and you're not even, you're down 25%. The degree of overestimation from this mean return -> "annualized return" calculation depends on what the returns distribution looks like. Here's the calculation used in main.js line 77 applied to a very extreme unrealistic example. I simulated 253 days…
Show HN: I discovered a trading algorithm that returns ~24.85% annually
81–90 of 134 posts
Re: Show HN: I discovered a trading algorithm that returns ~24.85% annually
#82As others have said, "Average return is just one statistic". When trading, losses hit harder than wins. Go up 50% then down 50% and you're not even, you're down 25%. The degree of overestimation from this mean return -> "annualized return" calculation depends on what the returns distribution looks like. Here's the calculation used in main.js line 77 applied to a very extreme unrealistic example. I simulated 253 days…
Where do you take that uniform distribution from? I don’t think any ETF would conform to that.
Re: Show HN: I discovered a trading algorithm that returns ~24.85% annually
#83Earlier quoted context omitted.
It's very simple, the best strategy for the last 20 years (with hindsight) would be to buy the shares that have performed best over this period, but it wouldn't work better than chance going forward. Obviously, sitting down and creating that "strategy" would be silly, nobody would think that would work. But if you're using ML or just test a million random strategies, you could end up with something along those lines,…
> the best strategy for the last 20 years (with hindsight) would be to buy the shares that have performed best over this period, The best strategy doesn't seem to me to be straightforward to calculate, even with perfect hindsight. It might be to continually switch in the short-term most profitable asset, after taking into account the transaction costs and risks of influencing the market.
Re: Show HN: I discovered a trading algorithm that returns ~24.85% annually
#84What software do you use to implement algorithms like this? Do you have to write your own python/other scripts and interact with trading API's for whatever service you use, or are there nice pre-written open source trading algorithms that make building stuff like this easier.
Here's one I found just with a google search: https://alpaca.markets/
Re: Show HN: I discovered a trading algorithm that returns ~24.85% annually
#85There is so much wrong with this I don't know where to start. But this seems common these days, I think it's due to the influx of inexperienced traders who have no proper statistical background.
I'll let ryanmonroe point out the first glaring problem with these types of simple "algorithms":
Re: Show HN: I discovered a trading algorithm that returns ~24.85% annually
#86Re: Show HN: I discovered a trading algorithm that returns ~24.85% annually
#87As others have said, "Average return is just one statistic". When trading, losses hit harder than wins. Go up 50% then down 50% and you're not even, you're down 25%. The degree of overestimation from this mean return -> "annualized return" calculation depends on what the returns distribution looks like. Here's the calculation used in main.js line 77 applied to a very extreme unrealistic example. I simulated 253 days…
Don’t know why this is on HN front page given it is an error.
Re: Show HN: I discovered a trading algorithm that returns ~24.85% annually
#88Earlier quoted context omitted.
It is a mean reversal bet. It can work. But what if one of the ETFs goes to zero? Then the algorithm will continously buy that all the way down. Erm - edit - scratch that: But what if one of the ETFs goes to the moon? Then the algorithm will continously sell that all the way up.
It will short it for one market day and then ignore it.
Re: Show HN: I discovered a trading algorithm that returns ~24.85% annually
#89Average return is just one statistic. You can earn an arbitrarily high daily average return by taking an ordinary strategy (e.g. buy and hold the S&P 500) and applying large amounts of leverage. Returns will be great until the strategy blows up. What was the volatility of this strategy? When backtested on the historical data, what was the maximum drawdown? What happens when trading costs or slippage (buying at the as…
He is trading Vanguard Sector ETFs, I doubt there is any issues with execution quality or getting blown up by a rise in volatility.