Next privilege 500 Rep.
Cast close & reopen votes
Next badge 0/1
~25k people reached
- 1 post edited
- 0 helpful flags
- 1 vote cast
Is MATLAB-generated code good enough for use in live trading?
Of course, if you generate code to C, then it won't be faster than C. Also, some functions may even be faster in native Matlab (see here for details: blogs.mathworks.com/loren/2011/11/14/…). However, our experience shows that with a smart strategy using MEX for bottlenecks, your overall performance will often beat both native C and Matlab. But, as I said, for many applications it's not worth the trouble. And, if you have good C skills, you might as well develop directly in C.
Which brokers offer a .NET stock trading API?
Also, you could use the ActiveX API from IB. It integrates fully into C# (including events, code completion in VS, etc.) and works very well. But the other remarks are also true, namely: 1.) it's not the easiest API to learn, and everything is event-based, which is good but more complex then sync calls. 2.) there's no way around TWS/Gateway, and the main problem here is that you need to log into TWS/Gateway once per day. Though there are some workarounds/hacks around that.
R: How feasible is it to store — and work with — tick data in a database connected to R?
Of course ODBC adds an overhead, just as JDBC does. But my experience is that for many applications you can neglect it, because it's just an overhead in terms of latency. Often, it's not the latency of a query that's important, but the execution of the query itself. And that is done in the respective database engine, no matter if you use a bridge to connect to it or not. My advice would always be to start with what's available for free, and scale up you tech stack (either by buying or by building) as need occurs.