|
From: Luigi B. <lui...@gm...> - 2024-01-31 16:51:55
|
Hello Rishi,
both stepsPerYear and timeSteps specify how many steps the generated
Monte Carlo paths will have, but in different ways: by passing timeSteps
you're specifying the total number of steps independently of the maturity,
and by passing stepsPerYear instead you're specifying, well, the steps per
year from now to the maturity. You can't pass both, as you might suspect.
>From your plots, you see that the time increases linearly with the steps,
mostly because they need work to be generated.
In the case of your option, the price doesn't change noticeably because
it's a European option. Regardless of the number of steps between now and
maturity, your simulation will end up with the same generated distribution
of underlying prices at maturity (because it only depends on the drift and
vol of the process), so the price will also be the same. To see an effect,
you could try using MCAmericanBasketEngine instead. It's not documented in
the page you linked, but it exists and the parameters it takes are the same.
Hope this helps,
Luigi
On Wed, Jan 31, 2024 at 11:57 AM Rishi Sreedhar <ris...@gm...>
wrote:
> Hi, very happy to have found this list!
>
> I am a beginner in quantitative finance and just started learning about
> options pricing for a project at work.
>
> I was using the code given here (
> https://quantlib-python-docs.readthedocs.io/en/latest/pricing_engines.html#basket-options)
> to price a vanilla European call min-basket option, but couldn't understand
> the role of the 'stepsPerYear' parameter.
>
> 1.) On running the calculations, I found that the stepsPerYear parameter
> has zero influence on the price of the option. Could someone please explain
> why that is so? [attaching a plot of the option price vs stepsPerYear with
> this email]
>
> 2.) How is the stepsPerYear parameter also different from the *timeSteps *
> parameter?
>
> 3.) What are some options for which the price does depend on the
> stepsPerYear parameter?
>
> Thank you so much for looking into this!
> Cordially,
> Rishi
>
> _______________________________________________
> QuantLib-users mailing list
> Qua...@li...
> https://lists.sourceforge.net/lists/listinfo/quantlib-users
>
|