Skip to contents

w formula implementation from modified Corrado-Su model.

Usage

csmw(sigma, time, mu3, mu4)

Arguments

sigma

volatility of the stock price.

time

time to option expiration in years.

mu3

skewness.

mu4

kurtosis.

Value

Vector with w.

Recycle rule

These arguments handle the recycle rule so vectors can be provided and once those vectors differs in length the recycle rule is applied.

See also

csmd for d from modified Corrado-Su model.\ csmq3 for Q_3 from modified Corrado-Su model.\ csmq4 for Q_4 from modified Corrado-Su model.\ csmprice for modified Corrado-Su option pricing formula.

Examples

csmw(0.25, 1.5, 0, -100:100 / 100)
#>   [1] -3.662109e-04 -3.625488e-04 -3.588867e-04 -3.552246e-04 -3.515625e-04
#>   [6] -3.479004e-04 -3.442383e-04 -3.405762e-04 -3.369141e-04 -3.332520e-04
#>  [11] -3.295898e-04 -3.259277e-04 -3.222656e-04 -3.186035e-04 -3.149414e-04
#>  [16] -3.112793e-04 -3.076172e-04 -3.039551e-04 -3.002930e-04 -2.966309e-04
#>  [21] -2.929687e-04 -2.893066e-04 -2.856445e-04 -2.819824e-04 -2.783203e-04
#>  [26] -2.746582e-04 -2.709961e-04 -2.673340e-04 -2.636719e-04 -2.600098e-04
#>  [31] -2.563477e-04 -2.526855e-04 -2.490234e-04 -2.453613e-04 -2.416992e-04
#>  [36] -2.380371e-04 -2.343750e-04 -2.307129e-04 -2.270508e-04 -2.233887e-04
#>  [41] -2.197266e-04 -2.160645e-04 -2.124023e-04 -2.087402e-04 -2.050781e-04
#>  [46] -2.014160e-04 -1.977539e-04 -1.940918e-04 -1.904297e-04 -1.867676e-04
#>  [51] -1.831055e-04 -1.794434e-04 -1.757812e-04 -1.721191e-04 -1.684570e-04
#>  [56] -1.647949e-04 -1.611328e-04 -1.574707e-04 -1.538086e-04 -1.501465e-04
#>  [61] -1.464844e-04 -1.428223e-04 -1.391602e-04 -1.354980e-04 -1.318359e-04
#>  [66] -1.281738e-04 -1.245117e-04 -1.208496e-04 -1.171875e-04 -1.135254e-04
#>  [71] -1.098633e-04 -1.062012e-04 -1.025391e-04 -9.887695e-05 -9.521484e-05
#>  [76] -9.155273e-05 -8.789062e-05 -8.422852e-05 -8.056641e-05 -7.690430e-05
#>  [81] -7.324219e-05 -6.958008e-05 -6.591797e-05 -6.225586e-05 -5.859375e-05
#>  [86] -5.493164e-05 -5.126953e-05 -4.760742e-05 -4.394531e-05 -4.028320e-05
#>  [91] -3.662109e-05 -3.295898e-05 -2.929688e-05 -2.563477e-05 -2.197266e-05
#>  [96] -1.831055e-05 -1.464844e-05 -1.098633e-05 -7.324219e-06 -3.662109e-06
#> [101]  0.000000e+00  3.662109e-06  7.324219e-06  1.098633e-05  1.464844e-05
#> [106]  1.831055e-05  2.197266e-05  2.563477e-05  2.929688e-05  3.295898e-05
#> [111]  3.662109e-05  4.028320e-05  4.394531e-05  4.760742e-05  5.126953e-05
#> [116]  5.493164e-05  5.859375e-05  6.225586e-05  6.591797e-05  6.958008e-05
#> [121]  7.324219e-05  7.690430e-05  8.056641e-05  8.422852e-05  8.789062e-05
#> [126]  9.155273e-05  9.521484e-05  9.887695e-05  1.025391e-04  1.062012e-04
#> [131]  1.098633e-04  1.135254e-04  1.171875e-04  1.208496e-04  1.245117e-04
#> [136]  1.281738e-04  1.318359e-04  1.354980e-04  1.391602e-04  1.428223e-04
#> [141]  1.464844e-04  1.501465e-04  1.538086e-04  1.574707e-04  1.611328e-04
#> [146]  1.647949e-04  1.684570e-04  1.721191e-04  1.757812e-04  1.794434e-04
#> [151]  1.831055e-04  1.867676e-04  1.904297e-04  1.940918e-04  1.977539e-04
#> [156]  2.014160e-04  2.050781e-04  2.087402e-04  2.124023e-04  2.160645e-04
#> [161]  2.197266e-04  2.233887e-04  2.270508e-04  2.307129e-04  2.343750e-04
#> [166]  2.380371e-04  2.416992e-04  2.453613e-04  2.490234e-04  2.526855e-04
#> [171]  2.563477e-04  2.600098e-04  2.636719e-04  2.673340e-04  2.709961e-04
#> [176]  2.746582e-04  2.783203e-04  2.819824e-04  2.856445e-04  2.893066e-04
#> [181]  2.929687e-04  2.966309e-04  3.002930e-04  3.039551e-04  3.076172e-04
#> [186]  3.112793e-04  3.149414e-04  3.186035e-04  3.222656e-04  3.259277e-04
#> [191]  3.295898e-04  3.332520e-04  3.369141e-04  3.405762e-04  3.442383e-04
#> [196]  3.479004e-04  3.515625e-04  3.552246e-04  3.588867e-04  3.625488e-04
#> [201]  3.662109e-04
csmw(0.25, 1.5, -100:100 / 100, 3)
#>   [1] -3.685527e-03 -3.637685e-03 -3.589844e-03 -3.542002e-03 -3.494160e-03
#>   [6] -3.446319e-03 -3.398477e-03 -3.350636e-03 -3.302794e-03 -3.254952e-03
#>  [11] -3.207111e-03 -3.159269e-03 -3.111428e-03 -3.063586e-03 -3.015744e-03
#>  [16] -2.967903e-03 -2.920061e-03 -2.872220e-03 -2.824378e-03 -2.776537e-03
#>  [21] -2.728695e-03 -2.680853e-03 -2.633012e-03 -2.585170e-03 -2.537329e-03
#>  [26] -2.489487e-03 -2.441645e-03 -2.393804e-03 -2.345962e-03 -2.298121e-03
#>  [31] -2.250279e-03 -2.202437e-03 -2.154596e-03 -2.106754e-03 -2.058913e-03
#>  [36] -2.011071e-03 -1.963229e-03 -1.915388e-03 -1.867546e-03 -1.819705e-03
#>  [41] -1.771863e-03 -1.724021e-03 -1.676180e-03 -1.628338e-03 -1.580497e-03
#>  [46] -1.532655e-03 -1.484813e-03 -1.436972e-03 -1.389130e-03 -1.341289e-03
#>  [51] -1.293447e-03 -1.245605e-03 -1.197764e-03 -1.149922e-03 -1.102081e-03
#>  [56] -1.054239e-03 -1.006397e-03 -9.585558e-04 -9.107142e-04 -8.628726e-04
#>  [61] -8.150310e-04 -7.671895e-04 -7.193479e-04 -6.715063e-04 -6.236647e-04
#>  [66] -5.758231e-04 -5.279815e-04 -4.801399e-04 -4.322983e-04 -3.844567e-04
#>  [71] -3.366151e-04 -2.887735e-04 -2.409319e-04 -1.930903e-04 -1.452487e-04
#>  [76] -9.740710e-05 -4.956550e-05 -1.723908e-06  4.611769e-05  9.395929e-05
#>  [81]  1.418009e-04  1.896425e-04  2.374841e-04  2.853257e-04  3.331673e-04
#>  [86]  3.810089e-04  4.288505e-04  4.766921e-04  5.245337e-04  5.723753e-04
#>  [91]  6.202168e-04  6.680584e-04  7.159000e-04  7.637416e-04  8.115832e-04
#>  [96]  8.594248e-04  9.072664e-04  9.551080e-04  1.002950e-03  1.050791e-03
#> [101]  1.098633e-03  1.146474e-03  1.194316e-03  1.242158e-03  1.289999e-03
#> [106]  1.337841e-03  1.385682e-03  1.433524e-03  1.481366e-03  1.529207e-03
#> [111]  1.577049e-03  1.624890e-03  1.672732e-03  1.720574e-03  1.768415e-03
#> [116]  1.816257e-03  1.864098e-03  1.911940e-03  1.959782e-03  2.007623e-03
#> [121]  2.055465e-03  2.103306e-03  2.151148e-03  2.198990e-03  2.246831e-03
#> [126]  2.294673e-03  2.342514e-03  2.390356e-03  2.438198e-03  2.486039e-03
#> [131]  2.533881e-03  2.581722e-03  2.629564e-03  2.677405e-03  2.725247e-03
#> [136]  2.773089e-03  2.820930e-03  2.868772e-03  2.916613e-03  2.964455e-03
#> [141]  3.012297e-03  3.060138e-03  3.107980e-03  3.155821e-03  3.203663e-03
#> [146]  3.251505e-03  3.299346e-03  3.347188e-03  3.395029e-03  3.442871e-03
#> [151]  3.490713e-03  3.538554e-03  3.586396e-03  3.634237e-03  3.682079e-03
#> [156]  3.729921e-03  3.777762e-03  3.825604e-03  3.873445e-03  3.921287e-03
#> [161]  3.969129e-03  4.016970e-03  4.064812e-03  4.112653e-03  4.160495e-03
#> [166]  4.208337e-03  4.256178e-03  4.304020e-03  4.351861e-03  4.399703e-03
#> [171]  4.447545e-03  4.495386e-03  4.543228e-03  4.591069e-03  4.638911e-03
#> [176]  4.686753e-03  4.734594e-03  4.782436e-03  4.830277e-03  4.878119e-03
#> [181]  4.925961e-03  4.973802e-03  5.021644e-03  5.069485e-03  5.117327e-03
#> [186]  5.165169e-03  5.213010e-03  5.260852e-03  5.308693e-03  5.356535e-03
#> [191]  5.404377e-03  5.452218e-03  5.500060e-03  5.547901e-03  5.595743e-03
#> [196]  5.643584e-03  5.691426e-03  5.739268e-03  5.787109e-03  5.834951e-03
#> [201]  5.882792e-03
csmw(0:100 / 100, 1.5, 0, 3)
#>   [1] 0.000000e+00 2.812500e-09 4.500000e-08 2.278125e-07 7.200000e-07
#>   [6] 1.757813e-06 3.645000e-06 6.752813e-06 1.152000e-05 1.845281e-05
#>  [11] 2.812500e-05 4.117781e-05 5.832000e-05 8.032781e-05 1.080450e-04
#>  [16] 1.423828e-04 1.843200e-04 2.349028e-04 2.952450e-04 3.665278e-04
#>  [21] 4.500000e-04 5.469778e-04 6.588450e-04 7.870528e-04 9.331200e-04
#>  [26] 1.098633e-03 1.285245e-03 1.494678e-03 1.728720e-03 1.989228e-03
#>  [31] 2.278125e-03 2.597403e-03 2.949120e-03 3.335403e-03 3.758445e-03
#>  [36] 4.220508e-03 4.723920e-03 5.271078e-03 5.864445e-03 6.506553e-03
#>  [41] 7.200000e-03 7.947453e-03 8.751645e-03 9.615378e-03 1.054152e-02
#>  [46] 1.153301e-02 1.259285e-02 1.372410e-02 1.492992e-02 1.621350e-02
#>  [51] 1.757812e-02 1.902713e-02 2.056392e-02 2.219198e-02 2.391485e-02
#>  [56] 2.573613e-02 2.765952e-02 2.968875e-02 3.182764e-02 3.408008e-02
#>  [61] 3.645000e-02 3.894143e-02 4.155844e-02 4.430520e-02 4.718592e-02
#>  [66] 5.020488e-02 5.336645e-02 5.667503e-02 6.013512e-02 6.375128e-02
#>  [71] 6.752812e-02 7.147035e-02 7.558272e-02 7.987005e-02 8.433724e-02
#>  [76] 8.898926e-02 9.383112e-02 9.886793e-02 1.041048e-01 1.095471e-01
#>  [81] 1.152000e-01 1.210689e-01 1.271592e-01 1.334765e-01 1.400263e-01
#>  [86] 1.468143e-01 1.538460e-01 1.611275e-01 1.686643e-01 1.764626e-01
#>  [91] 1.845281e-01 1.928671e-01 2.014855e-01 2.103896e-01 2.195856e-01
#>  [96] 2.290799e-01 2.388787e-01 2.489886e-01 2.594160e-01 2.701676e-01
#> [101] 2.812500e-01