Note: This page has been translated by MathWorks. Click here to see

To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

Price European, Bermudan, or American vanilla options using Monte Carlo simulations

`Price = optstockbyls(RateSpec,StockSpec,OptSpec,Strike,Settle,ExerciseDates)`

`Price = optstockbyls(___,Name,Value)`

```
[Price,Path,Times,Z]
= optstockbyls(RateSpec,StockSpec,OptSpec,Strike,Settle,ExerciseDates)
```

```
[Price,Path,Times,Z]
= optstockbyls(___,Name,Value)
```

returns vanilla option prices using the Longstaff-Schwartz model.
`Price`

= optstockbyls(`RateSpec`

,`StockSpec`

,`OptSpec`

,`Strike`

,`Settle`

,`ExerciseDates`

)`optstockbyls`

computes prices of European, Bermudan, and American
vanilla options.

For American and Bermudan options, the Longstaff-Schwartz least squares method is used to calculate the early exercise premium.

adds
optional name-value pair arguments.`Price`

= optstockbyls(___,`Name,Value`

)