Timeline for Advice on learning C++ and its integration with Python/R/MATLAB for quantitative finance
Current License: CC BY-SA 4.0
12 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
May 19, 2020 at 14:01 | comment | added | Stéphane | @jbs Eg.: To price options, I might have to use Monte Carlo simulations. It starts to matter when you have tens of thousands of contracts to price inside a maximum likelihood estimation. You can vectorize some of the work to speed it up, but you cannot vectorize everything in Python -- you'll have to work with loops somewhere for this. Alternatively, you can call compiled C++ code to do it and, chances are, that code will run WAY faster. That's why people use Numba in Python or Mex files in MATLAB. | |
May 19, 2020 at 11:01 | comment | added | user24980 | I though Numpy was already written in C, don't understand the point of Numba? | |
May 19, 2020 at 5:42 | answer | added | chrisaycock | timeline score: 0 | |
Apr 24, 2020 at 18:47 | vote | accept | Stéphane | ||
Apr 22, 2020 at 11:44 | comment | added | amdopt | Using the Numba package (numba.pydata.org) to compile mathematical functions in C would be the way to go. You get the speed of C within Python. Also, FWIW, Python isn't just for scripting. If you really want to build all the objects from scratch, OOP in Python is no different in principle than in C++. | |
Apr 22, 2020 at 9:00 | history | tweeted | twitter.com/StackQuant/status/1252884884298715137 | ||
Apr 22, 2020 at 8:06 | comment | added | Lisa Ann | C++ is the fastest when it comes to Monte Carlo simulations, and you can easily compile and source your functions in R through the excellent Rcpp package. The other way is to use Python and JIT compilation through Numba, which should be just a bit slower than C++ but doesn't require to switch between two different languages. OOP is nice here, but if you use QuantLib-Python you already have very structured objects: you can relax and enjoy some basic functional programming design. | |
Apr 21, 2020 at 22:21 | answer | added | ir7 | timeline score: 1 | |
Apr 21, 2020 at 20:36 | history | edited | Stéphane | CC BY-SA 4.0 |
deleted 2 characters in body
|
Apr 21, 2020 at 20:16 | answer | added | Oscar | timeline score: 2 | |
Apr 21, 2020 at 20:07 | comment | added | Stéphane | Most of what I do involves econometrics. I did some work in macroeconomic forecasting using machine learning. It was uber time consumming -- we're talking about half a million forecasting errors in the main backtest across models, variables and horizons. All of my current projects involve econometrics and most of my work will involve a heavy empirical element or simulations... So, econometrics, mostly. | |
Apr 21, 2020 at 19:15 | history | asked | Stéphane | CC BY-SA 4.0 |