Looks like you're using global variables, which is the first no-no of Julia
performance:

http://julia.readthedocs.org/en/latest/manual/performance-tips/


On Sun, Feb 16, 2014 at 3:02 AM, Pithawat Tan Vachiramon
<[email protected]>wrote:

> I've been testing out performance of simple Monte Carlo simulation for a
> call option, basically generating random samples of outcome and taking a
> mean. I did this with vectorization and also in a loop. What I found is
> that Julia is *way* slower than Matlab or numpy:
>
> Julia
> Vectorized: 50.16s
> Loop: 358.6s
>
> Matlab
> Vactorized: 6.6s
>
> Numpy
> Vectorized: 10.31s
>
> The codes are in here:
>
> http://pithawat.com/post/monte-carlo-simulation
> http://pithawat.com/post/first-brush-with-julia
>
> Anyone care to explain why?
>

Reply via email to