Montecarlo
Forums › ProRealTime English forum › General trading discussions › Montecarlo
- This topic has 13 replies, 6 voices, and was last updated 8 years ago by Nicolas.
-
-
05/31/2016 at 9:46 AM #8489
Hi Nicolas… in a previous interesting post you mentioned that you were going to explain a little bit montecarlo and forward test analysis. http://www.prorealcode.com/blog/avoid-equity-curve-fitting-with-probacktest-trading-strategy-optimisation/
This site is amazing and I found thousand of good thing in here but I found also some curve fitted strategies.
We need all to learn more about montecarlo and forward test… Would you like to open the discussion?
I have build with a friend my own montecarlo excel file and we have tried together to understand it but the conclusion it is that for any kind of TS we make the analysis we got very similar results! this mean 2 things, or the montacralo is useful or I don’t know how to read the results well…
Would you be so kind to teach us a little bit?
If all the users will start to use it together with the backtest I am sure that we will get much better TS in the future in your library!
05/31/2016 at 12:17 PM #852505/31/2016 at 12:37 PM #852605/31/2016 at 12:38 PM #8527If nicolas will teach us a little how to read it I can share the one created by me and my friend.
At the moment all the Ts that I have tested with it gives similar result and no big decision can be made….
In the mean time if anyone want to test his system with montecarlo can send me their data and I will send the results.
06/02/2016 at 11:52 AM #863106/02/2016 at 12:36 PM #8636Well, that’s a long debate and a big subject. Is Monte Carlo analysis trustable? I think it does. I don’t know how you made your matrix David, so maybe there are something that don’t make your random trades so “random”. There are many ways to deal with the trades PnL datas from backtest, and there are no “one way” to do it. What make sense to me is to introduce: 1/ non traded days 2/ a criteria to give an average of positive trades or not 3/ gain and loss must be adapted with std dev of their average to simulate spread, fees, slippage, etc.
In any case, if your backtest average gain is superior to your average loss, your distribution will be likely other negative profits level with a large proportion. So what we want here is to simulate what we should expect with future market, so playing with 1/ and 2/ with much more simulated trades than your backtest/forward test has, is the main purpose of this test. Sometimes, reducing percentage of profitable trades of only 1% make things dramatic..
There are a lot of academic papers that deal with Monte Carlo analysis and not only for financial purpose, if you have time to spend on maths theory and headaches don’t afraid you : http://www.jurn.org/#gsc.tab=0&gsc.q=monte%20carlo&gsc.sort=
I just google it and found this nice page on Investopedia : http://www.investopedia.com/articles/financial-theory/08/monte-carlo-multivariate-model.asp
06/02/2016 at 5:31 PM #8660Nicolas, what do you think if we take a Ts that works with normal results and the same one curve fitted. After this we compare the montecarlo test between them? (In the mean time I check with my friend why my montecarlo does not work soo good)
We will start to learn something on real tests. Maybe not everyone want to know the mathematics that there is behind it (really complicated) but only to know how to read the results. What the others thinks?
06/02/2016 at 5:38 PM #866206/03/2016 at 10:31 AM #8716Do you have a TS to propose? I will make the optimization…
06/12/2016 at 8:37 AM #9266Hi Guys/Nicolas,
What do you use Monte Carlo for? What is it that you are trying to determine? I am new to MC, and how it can be used in building strategies.
What I have been able to do so far:
- Simulate/generate new data for an instrument by using drift, standard deviation, variance, PDR, etc.
- Calculate possible max drawdowns by randomizing/reordering trade/backtest data – in this test the profit stays the same for all simulations.
Nicolas, how do you setup your simulated equity charts (MC simulations) specific to a trading strategy – what are your inputs, variables, etc? What do you vary for each simulation?
I am happy to try to figure this out, but would appreciate some direction in this regard.
Thanks
Stef
06/12/2016 at 11:02 AM #9274Hi Stef / everyone,
Setting up Monte Carlo to simulate a ‘random walk’ is the first step. The simulated data needs to possess the same characteristics as the backtest data (i.e. Open, high, low, close). Tick by tick data would be optimal however haven’t thought as to how this can be done.
The next part, which is the trickiest – is to translate the Trading System from PRT to Excel so that it can perfectly execute the logic against the new simulated candlestick data (i.e. Forward testing). Would be interesting to see how this can be achieved.
Any attempt to run MC on the TS backtested results will only be inherently biased.
Thoughts welcome – cheers
06/12/2016 at 12:04 PM #9277You are right about biased results of the MC simulation because of use of the backtest data, that’s why in my own MC test I introduce a wide varieties of random behaviours of trades. In addition, you can add many more lines of trades than the backtest has done because of limitation of history.
I already told what I do in these tests, in my previous reply: http://www.prorealcode.com/topic/montecarlo/#post-8636
About totally random OHLC and test the strategy with, you have many other instruments to test with the same strategy in PRT already 🙂
06/12/2016 at 1:57 PM #928906/12/2016 at 2:20 PM #9290 -
AuthorPosts