October 7th, 2001, 4:15 pm
as the co-author of the jackson book, and responsible for writing the code let me add some thoughtsi wanted the code to have consistency throughout the book (and hence separate functions for d1 and d2) whilst also not just not borrowing code from othersi also wanted the code to be as clear as possiblewith analytic solutions differences in code are likely to be immaterial as regards speed, though one tries harder to optimise code for the more demanding numerical methods (such as using vectors rather than matrices when using binomial trees)sometimes differences in code reflect different emphasis in teaching (bs recast with inputs as the mean and variance of the ln distribution, or d2 defined before d1 to reflect d2's greater role in the derivation with probabilities and measures)in our code and with our background in spreadsheets i've also tried to use as many excel functions as possible (including those involving arrays) before looking for vba / standard programming techniques (whereas others may say find it easier to translate something more or less straight from numerical recipes)in passing, it would be nice to see some of the older and less sophisticated methods (such as dare i say the crr tree parameters for standard options) being replaced by their newer and more efficient substitutes