RicardoSantos

Function - simple* Markov Chain Monte Carlo Simulation (MCMC)

Example function of a markov chain monte carlo simulation.
Open-source script

In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in a publication is governed by House Rules. You can favorite it to use it on a chart.

Want to use this script on a chart?

Kommentarer

500 coins
+1 Svara
Hi Sir , im the one of admirer of your old Markov Chain script. Thanks for your effort on that script.I have a little question :
500 coins
Svara
Noldo Noldo
@Noldo, If we change line 43 and line 44 ( i_iterations and i_start ) can we do more short therm predictions ?
For example : For 1H TF : i_iterations = 100 * 24 * 20 (Converting 1M to 1H timeframe ) and i _start = 500 * 24 * 20
Best regards.
Svara
@Noldo, the i_start value would be something like price value the simulation starts at, iterations is the number of steps in the simulation, for running multiple simulations you would need to run the function inside a extra loop with the number of simulations, running that high number of simulations might not be feasible with pinescript.
+1 Svara
Noldo RicardoSantos
@RicardoSantos, "if bar_index < i_iterations
output := array.get(M, bar_index)"
I tried to comply with this command and blocked the na value at low timeframes.
Svara
Looks like a rate of change of your VPN signal might be useful. Using only VPN on trigger levels is to late, it is more of a trailing indicator then a useful leading indicator to trigger an entry/exit.
Svara
nice analysis
Svara
Since when has PineScript had a random() function? Nice.
Svara
Thanks for sharing!
Svara
This publication is now featured in our Editors' Picks: https://www.tradingview.com/scripts/editors-picks/ .
In the name of all TradingViewers, thank you for your valuable contribution to the community, and congrats!
Svara
Hem Aktie-screener Forex-screener Krypto-screener Ekonomisk kalender Om Diagramfunktioner Priser Tipsa en vän Ordningsregler Hjälpcenter Webbsidor och mäklarlösningar Widgets Diagramlösningar Lightweight Charting Library Blogg och nyheter Twitter
Profil Profilinställningar Konto och fakturering Hänvisade vänner Mynt Mina kölappar Hjälpcenter Privata meddelanden Chatt Logga ut