Trading System Development

Discussion in 'Automated Trading' started by gvphubli, Jan 19, 2015.

  1. gvphubli

    gvphubli

    Since I know SQL - I started from there.

    I wrote a simple back-testing using "Simple Moving Average" and running it against S&P 500 symbols. From Raw data (from Yahoo finance for last 10 years) processing to calculating SMA and running a simulated trades it took about 20 minutes on my laptop.

    So I was wondering how the systems like the one at "www.stockfetcher.com" are built, where you can plugin ANY filters and logic and get the entire backtest results done in about 5 minutes with all the performance matrics like equity curve, drawdowns calculated

    My question is more on coding pattern and architecture of such a system. I understand I can use pre-build Technical Analysis libraries to save quiet a bit of work.
     
  2. southall

    southall

    How many bars altogether?
    SQL is not the fastest way to process bars data.
    My simple java backtester can do about 1 million bars a second on an old intel cpu.
     
  3. RTFF!!! There is plenty information on this site to get you started. But my recommendation for you: It makes very little to no sense to start with something you know. You may want to adjust your project management approach. Start thinking what you try to achieve and then you look what tools will aid you in that process. SQL is about as bad as it gets a tool to store and retrieve time series. Good luck!


     
  4. Heh don't listen to the above. Keep doing what you doing.
    SQL is GREATTTT, use Stored Procedure to add speed.
    And start tuning all the buffer and storage engine settings. use myisam
    table type if your using mysql derivative.
     
  5. sure SQL is GREATTTT for relational data, unfortunately not for time series.

     
  6. Hey the guy wants to do it in SQL, let him.

    What I don't get is why people here are so obssesed with writing their own backtesting
    engine, they really don't want to spend a few hundred bucks on readymade tools.

    Like the last time you and I sparred on a comment thread about an NXcore implementation.
     
  7. this would work for newbies. For anyone who takes up algorithmic trading as a career, has worked for many years in the financial trading space, and wants to approach this career professionally, a couple hundred off-the-shelf solutions just do not offer what is required. Name me a single solution that one can buy that offers capabilities you deem sufficient. I will show you 3 easy parts your suggestion would fail even in a simple environment.

     
  8. For what the op is trying to do above, tradestation would be more then enough.

    Ok So I use my custom ML SVM GA algos to find alphas on historical OHLC
    no low lat stuff and orderbook.

    verify the results and the develop the visualization and autotrade live in multicharts.


    Whats wrong with that ?
     
  9. gvphubli

    gvphubli

    Replying to couple of replies in single post:

    southall: I have last 10 year daily EOD, for about 2000 symbols. When I said slow the issue was with dynamic SMA or RSI calculation for different parameters.
    What Java backtester are you using - is it custom code ? any pointers/sample code would help.

    volpunter: RTFF !! - yes I did it. But most of it talk about different tools commercial and open source. Have looked at http://gbeced.github.io/pyalgotrade/, Python and related packages, R with Quantmod etc but most of the samples that document are for mostly single ticker for a bunch of tickers like in Portfolio. Also the learning curve involved is high (I am not complaining, I am just saying). I also looked at Quantopian - that expects me to type all the symbols that I want to test against like "context.security = symbol('AAPL')" and don't see an option to specify a group like SNP or DOW or RUSSEL index

    AdrianHagh81: Spending money on a back testing software I agree, but usually the coding style used is harder to learn. Specifically when i am trying to deviate from the standard indicators. Once I asked question to Ninja Trader support about how to rank stocks by a given technical indicator and their answer was - we offer training and custom coding/indicators.

    I am not at all looking at automated trading, I am just looking for back testing solution. And my question is not just about backtesting, also want to know how they make such a software to do so.

    Currently I am evaluating/looking at StrataSearch !
     
  10. gvphubli

    gvphubli

    And thanks for everyone's ideas and comments
     
    #10     Jan 20, 2015