C# and NMath for Computational Finance and Econometrics

1.9k views Asked by At

I am currently (mostly) using C++ for computationally intensive econometrics in my research. I have been wanting to move to a more productive environment. D sounds promising, but perhaps not mature enough for me to be fully productive currently. I came across C# and the NMath library recently. It seems very impressive. Is anyone using these to such an end? What are your experiences? I am willing to give up some run-time speed if it boosts my productivity overall (tenure clock is ticking). You thoughts and suggestions appreciated!

3

There are 3 answers

3
James Webster On BEST ANSWER

I assume you are refering to Centerspace's NMath product?

We have recently started using them in a production application; albeit very lightly so far (performing a linear regression to determine the relationship between GJ of gas input to a gas turbine vs MW out; technically this is a feature of NMath Stats). It has been a pleasure to use so far, and their support was very quick in responding to an expired evaluation license whilst waiting for our finance department to process their invoice.

As far as performance is concerned, it does use the Intel Math Kernel Library where it can, so performance should be good; it hasn't caused any negative performance impact for our limited use.

I'm looking forward to using the library elsewhere in our application as it is appropriate!

4
Justin W On

I work for an economics firm (EMSI) and we use D for most of our high-performance computation needs. The native speed and efficiency are critical, but it provides a higher-level of abstraction than C and fewer gotchas than C++ (IMHO). It's very simple to interface with BLAS, Intel MKL, etc. which we use to power the massive matrix operations behind our realtime I/O models. One nice thing about D productivity-boosting that is often overlooked is the blazingly-fast compiler--I never bother with progressive builds, even on very large projects.

0
user492238 On

My recommendation goes towards ILNumerics. It seems to be one of the fastest libraries around. It went commercial several month ago but I have been using it since years already, formerly as open source library.

We had to convert masses of Matlab code for deploying an application to customers. ILNumerics was our first (and basically the only) choice, since it uses the same syntax as Matlab. Also, its array classes can handle n dimensions and lot of subarray stuff which was important to us as well. You'll find a nice code sample here.

In my opinion, the only drawback: lack of specialized functions for engeneering and only basic statistics implmented. So it is very convenient to build your own algorithm (using std, cov, var, mean, abs etc.) then unpacking any HILO-whatever indicator out of the box.