C++ C# or C for backtesting (no ninja or multicharts C#, vanilla only with libraries) - Platforms and Indicators | futures io social day trading
futures io futures trading


C++ C# or C for backtesting (no ninja or multicharts C#, vanilla only with libraries)
Updated: Views / Replies:3,813 / 11
Created: by treydog999 Attachments:0

Welcome to futures io.

(If you already have an account, login at the top of the page)

futures io is the largest futures trading community on the planet, with over 90,000 members. At futures io, our goal has always been and always will be to create a friendly, positive, forward-thinking community where members can openly share and discuss everything the world of trading has to offer. The community is one of the friendliest you will find on any subject, with members going out of their way to help others. Some of the primary differences between futures io and other trading sites revolve around the standards of our community. Those standards include a code of conduct for our members, as well as extremely high standards that govern which partners we do business with, and which products or services we recommend to our members.

At futures io, our focus is on quality education. No hype, gimmicks, or secret sauce. The truth is: trading is hard. To succeed, you need to surround yourself with the right support system, educational content, and trading mentors Ė all of which you can find on futures io, utilizing our social trading environment.

With futures io, you can find honest trading reviews on brokers, trading rooms, indicator packages, trading strategies, and much more. Our trading review process is highly moderated to ensure that only genuine users are allowed, so you donít need to worry about fake reviews.

We are fundamentally different than most other trading sites:
  • We are here to help. Just let us know what you need.
  • We work extremely hard to keep things positive in our community.
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts.
  • We firmly believe in and encourage sharing. The holy grail is within you, we can help you find it.
  • We expect our members to participate and become a part of the community. Help yourself by helping others.

You'll need to register in order to view the content of the threads and start contributing to our community.  It's free and simple.

-- Big Mike, Site Administrator

Reply
 
Thread Tools Search this Thread
 

C++ C# or C for backtesting (no ninja or multicharts C#, vanilla only with libraries)

  #1 (permalink)
Elite Member
seoul, Korea
 
Futures Experience: Intermediate
Platform: Multicharts
Broker/Data: CQG, DTN IQfeed
Favorite Futures: YM 6E
 
treydog999's Avatar
 
Posts: 894 since Jul 2012
Thanks: 291 given, 1,006 received

C++ C# or C for backtesting (no ninja or multicharts C#, vanilla only with libraries)

I am wondering if anyone has any experience doing backtesting and pricing in C/C++ family of languages. I want to exclude ninjatrader and Multicharts C# versions due to the fact it is actually wrappered using their own proprietary platform. I am thinking in a platform independent and totally customization solution.

I was looking at QuantLib library. Anyone have any experience?

For a end to end tech stack, from backtesting to deployment I think C family languages will execute the fastest but develop the slowest. Also opinions on the garbage collection of C# vs C++? Any thoughts?

Reply With Quote
The following 2 users say Thank You to treydog999 for this post:
 
  #2 (permalink)
Quick Summary
Quick Summary Post

Quick Summary is created and edited by users like you... Add FAQ's, Links and other Relevant Information by clicking the edit button in the lower right hand corner of this message.

 
  #3 (permalink)
Elite Member
@ Germany
 
Futures Experience: Beginner
Platform: NinjaTrader
Broker/Data: Mirus Futures/Zen-Fire
Favorite Futures: FDAX
 
Posts: 439 since Nov 2011
Thanks: 254 given, 368 received


I've build my own test environment to be independent from other Software vendors. It's a tough way because you have to build every functionality by yourself. But therefore you can focus your work at special topics, which are much important for your type of system. It's not a generic approach, but you can iterate thru your system development much faster. I use C# because i have to develop as fast as possible. It doesn't bother me if the backtest runs in seconds or minutes. You can even optimize C# code.

If you use plain C# and common components you can always transfer your c# code (trading system core - no gui stuff) into c++ code easily. There are a some tools for it available.

Reply With Quote
The following user says Thank You to Koepisch for this post:
 
  #4 (permalink)
Elite Member
seoul, Korea
 
Futures Experience: Intermediate
Platform: Multicharts
Broker/Data: CQG, DTN IQfeed
Favorite Futures: YM 6E
 
treydog999's Avatar
 
Posts: 894 since Jul 2012
Thanks: 291 given, 1,006 received


Koepisch View Post
I've build my own test environment to be independent from other Software vendors. It's a tough way because you have to build every functionality by yourself. But therefore you can focus your work at special topics, which are much important for your type of system. It's not a generic approach, but you can iterate thru your system development much faster. I use C# because i have to develop as fast as possible. It doesn't bother me if the backtest runs in seconds or minutes. You can even optimize C# code.

If you use plain C# and common components you can always transfer your c# code (trading system core - no gui stuff) into c++ code easily. There are a some tools for it available.

Thanks for the reply. What do you think of doing your stuff in MATLAB / R / PYTHON for rapid proto typing first then "translating" to C# C++. I mean it is a lot of hassle and may introduce new bugs, but it may be worth it as you can test more models more quickly. Although I think the end to end tech stack solution has a lot of pluses it also requires the most amount of development time as you mentioned. Atleast R / MATLAB / Python have pre built backtesting and statistical analysis tools vs say C++ which has Quantlib but its pretty stark compared to R which has 8000 or so librarys.

Reply With Quote
 
  #5 (permalink)
Elite Member
@ Germany
 
Futures Experience: Beginner
Platform: NinjaTrader
Broker/Data: Mirus Futures/Zen-Fire
Favorite Futures: FDAX
 
Posts: 439 since Nov 2011
Thanks: 254 given, 368 received


treydog999 View Post
Thanks for the reply. What do you think of doing your stuff in MATLAB / R / PYTHON for rapid proto typing first then "translating" to C# C++. I mean it is a lot of hassle and may introduce new bugs, but it may be worth it as you can test more models more quickly. Although I think the end to end tech stack solution has a lot of pluses it also requires the most amount of development time as you mentioned. Atleast R / MATLAB / Python have pre built backtesting and statistical analysis tools vs say C++ which has Quantlib but its pretty stark compared to R which has 8000 or so librarys.

I looked at python and numpy in the past, but because i was new to it i never would as fast as in my current programming language. For myself i don't waste any time in searching for the approbiate library or getting familiar with it. If i need a functionality i'm much quicker in doing it myself with lots of freedom how to do it. But if you want get much of common statistics/functions which a "Quant Lib" provides, then invest time in evaluating these libs.

Reply With Quote
The following user says Thank You to Koepisch for this post:
 
  #6 (permalink)
Trading Apprentice
New York City + New York
 
Futures Experience: Intermediate
Platform: TradeStation
Favorite Futures: Forex
 
Piasa's Avatar
 
Posts: 2 since Apr 2015
Thanks: 7 given, 0 received

Try out R

For the last 5 years I've used R as my primary quant tool. The number of functions and libraries is vast. And over the last year and a half the execution speed has become very high, probably due to the core routines being converted to c++. The greatest advantages, compared to other platforms and systems I've used is in the very powerful date/calendar management libraries, wide variety of high-quality graphics and charting packages, and finally the comprehensive statistical and optimization tools. Also useful are the data loading connections to a variety of the usual data sources. Also its free.

The R user community has grown rapidly, especially over the last 3 or 4 years. It is well on its way to outpacing SAS as the most popular data analysis system.

There are two challenges to using R (1) The script-learning curve is a bit steep. The syntax is powerful, but is a somewhat confusing mix of functional and object-oriented paradigms, and (2) Choosing the best libraries amongst the >5000 and counting, is a challenge. The best starting point is to read some of the introductory articles and guides found on the R foundation web site. It's worth considering if you plan on extensive back testing and modeling efforts.

Reply With Quote
 
  #7 (permalink)
Elite Member
seoul, Korea
 
Futures Experience: Intermediate
Platform: Multicharts
Broker/Data: CQG, DTN IQfeed
Favorite Futures: YM 6E
 
treydog999's Avatar
 
Posts: 894 since Jul 2012
Thanks: 291 given, 1,006 received


Piasa View Post
For the last 5 years I've used R as my primary quant tool. The number of functions and libraries is vast. And over the last year and a half the execution speed has become very high, probably due to the core routines being converted to c++. The greatest advantages, compared to other platforms and systems I've used is in the very powerful date/calendar management libraries, wide variety of high-quality graphics and charting packages, and finally the comprehensive statistical and optimization tools. Also useful are the data loading connections to a variety of the usual data sources. Also its free.

The R user community has grown rapidly, especially over the last 3 or 4 years. It is well on its way to outpacing SAS as the most popular data analysis system.

There are two challenges to using R (1) The script-learning curve is a bit steep. The syntax is powerful, but is a somewhat confusing mix of functional and object-oriented paradigms, and (2) Choosing the best libraries amongst the >5000 and counting, is a challenge. The best starting point is to read some of the introductory articles and guides found on the R foundation web site. It's worth considering if you plan on extensive back testing and modeling efforts.

Thanks for recommending R, I am actually fairly well versed in it myself. However it is just not fast enough. Yes the underlying libraries may be written in C/C++/Fortran, however control structures (for loops, if else) are really slow. apply functions works fine if you just want to run something against all the rows of something, or all the columns of something. But it does not work for creating an event based back tester, which requires for loops in order to expose each new event or tick.

Also the multi core/parallel functionality of R is low, python is worse with its GIL(global interpreter lock). But if you are going to work with intraday data on dozens of instruments your going to be waiting hours. C#/C++/Java etc have much better parallel computing capabilities.

Reply With Quote
 
  #8 (permalink)
Elite Member
San Diego, CA
 
Futures Experience: Intermediate
Platform: x_trader pro, Excel
Broker/Data: Advantage
Favorite Futures: CL
 
baywolf's Avatar
 
Posts: 47 since Sep 2009
Thanks: 24 given, 23 received

To answer your original question, yes I have experience with C# and backtesting. For similar reason as Koepisch, I am more productive with C# syntax. For me, coder productivity is the most important thing. Coder enjoyment comes in second. Execution performance has not been an issue for me with C#.

Now, that being said, If I began my journey today, I would go with Python. I am slowly switching over to python in my dev environment, fwiw.

For me, python is also enjoyable to write. The syntax just makes sense to me, where as when I started (and failed) to learn R, it was nothing but frustration. I knew I wasnt going to be happy so I stopped early in to my education.

Python also has a following in the data science community. In higher education it appears they either will gravitate towards python or R. So I guess either will be fine. My thinking is that if you come from a computer science background you should go python, and if you feel more comfortable working with GUI based tools, then maybe you might choose R?

Reply With Quote
 
  #9 (permalink)
Elite Member
Jacksonville, Florida United States
 
Futures Experience: Intermediate
Platform: NT8, Fully custom
Broker/Data: NT Brokerage, Interactive Brokers
Favorite Futures: ES
 
Jasonnator's Avatar
 
Posts: 69 since Dec 2014
Thanks: 19 given, 44 received

I'm taking a close look at StockSharp for exactly that; a true tick level backtester. Depending on your C# abilities, it might be worth a look.

Reply With Quote
 
  #10 (permalink)
Trading Apprentice
Lalin Pontevedra Spain
 
Futures Experience: Advanced
Platform: Ninjatrader IB
Favorite Futures: EURUUSD
 
Posts: 7 since Sep 2013
Thanks: 4 given, 5 received


I've been reading a couple interesting opinions here regarding building your own, independent trading platform, so ditching any third-party software. I'm an intermediate level programming skill trader, basically in C#. I've been wondering if is it really worth programming your own platform in a Broker's Api, looking for achieving better performance, solving sync issues...etc To be honest I've been analyzing a couple of advanced samples and it seems to be really out of my league.

Any comment will be highly appreciated

Reply With Quote
The following user says Thank You to pstrusi for this post:

Reply



futures io > > > C++ C# or C for backtesting (no ninja or multicharts C#, vanilla only with libraries)

Thread Tools Search this Thread
Search this Thread:

Advanced Search



Upcoming Webinars and Events (4:30PM ET unless noted)

Linda Bradford Raschke: Reading The Tape

Elite only

Adam Grimes: TBA

Elite only

NinjaTrader: TBA

January

Ran Aroussi: TBA

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
[ASK] Multicharts backtesting problem - pls help jacoGreeff MultiCharts 7 September 2nd, 2014 07:15 PM
Backtesting and Research: MultiCharts or AmiBroker dnof AmiBroker 74 February 29th, 2012 03:21 PM
MultiCharts and Backtesting ehlaban Elite EasyLanguage Automated Trading 4 December 7th, 2011 02:19 PM
vanilla options mukhi Options on Futures 1 April 30th, 2011 07:30 AM
MultiCharts backtesting and spread arjfca The Elite Circle 3 September 26th, 2010 09:06 AM


All times are GMT -4. The time now is 12:48 PM.

Copyright © 2017 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432, info@futures.io
All information is for educational use only and is not investment advice.
There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
no new posts
Page generated 2017-12-11 in 0.15 seconds with 19 queries on phoenix via your IP 54.145.16.43