You may want to take a look at http://quantopian.com/, who make an engine that does just that. A lot of brokers actually support this.
The reason appears to be that there are lots of stock trading packages that people want to use (and to be fair, most brokers' interfaces suck somewhat. Also one interface for 2-3 brokers sounds appealing to me).
Most API's also let you play with the "fake money" accounts of the brokers. But keep in mind that they usually cheat on transaction costs in those modes.
You may want to read a lot of the algorithms on Quantopian. To be frank, the only one that really makes sense to me is the "auto-rebalancing" approach. What this does it it keeps your investment at what you set it.
Say you invest 50% in automotive stocks and 50% in nasdaq stocks. Nasdaq goes up 10% -> it sells 5% of the profit and invests it into automotrive stocks. This is one of the few algorithms that seems to :
1) beat the market
2) actually spreads risk around (or it seems to me it does, depends on your investment spread I guess)
I had actually looked into quantopian when I was getting started, but decided not to use that for my primary source of backtesting because they place limitations on users since that reduces pressure on their systems, allowing them to scale. This restricts backtesting ability and was a dealbreaker for me. The publicly shared algorithms, on the other hand, seem like they can provide a lot of insight, and I will look into those. Thanks!
The reason appears to be that there are lots of stock trading packages that people want to use (and to be fair, most brokers' interfaces suck somewhat. Also one interface for 2-3 brokers sounds appealing to me).
Here is an article about one such trading API:
http://www.quantstart.com/articles/Using-Python-IBPy-and-the...
Most API's also let you play with the "fake money" accounts of the brokers. But keep in mind that they usually cheat on transaction costs in those modes.
You may want to read a lot of the algorithms on Quantopian. To be frank, the only one that really makes sense to me is the "auto-rebalancing" approach. What this does it it keeps your investment at what you set it.
Say you invest 50% in automotive stocks and 50% in nasdaq stocks. Nasdaq goes up 10% -> it sells 5% of the profit and invests it into automotrive stocks. This is one of the few algorithms that seems to :
1) beat the market
2) actually spreads risk around (or it seems to me it does, depends on your investment spread I guess)