diff --git a/vnpy/pricing/black.py b/vnpy/pricing/black.py index c3bd8a2a..ecc5ae3e 100644 --- a/vnpy/pricing/black.py +++ b/vnpy/pricing/black.py @@ -68,7 +68,7 @@ def calculateTheta(f, k, r, t, v, cp): """计算Theta值""" price1 = calculatePrice(f, k, r, t*STEP_UP, v, cp) price2 = calculatePrice(f, k, r, t*STEP_DOWN, v, cp) - theta = (price1 - price2) * (t * STEP_DIFF * 240) + theta = -(price1 - price2) / (t * STEP_DIFF * 240) return theta #---------------------------------------------------------------------- @@ -76,7 +76,7 @@ def calculateVega(f, k, r, t, v, cp): """计算Vega值""" price1 = calculatePrice(f, k, r, t, v*STEP_UP, cp) price2 = calculatePrice(f, k, r, t, v*STEP_DOWN, cp) - vega = (price1 - price2) / (v * STEP_DIFF * 100) + vega = (price1 - price2) / (v * STEP_DIFF * 100) return vega #---------------------------------------------------------------------- diff --git a/vnpy/trader/app/optionMaster/__init__.py b/vnpy/trader/app/optionMaster/__init__.py index 5335fdb2..05ff3d30 100644 --- a/vnpy/trader/app/optionMaster/__init__.py +++ b/vnpy/trader/app/optionMaster/__init__.py @@ -7,4 +7,4 @@ appName = 'OptionMaster' appDisplayName = u'OptionMaster' appEngine = None appWidget = None -appIco = 'rm.ico' \ No newline at end of file +appIco = 'om.ico' \ No newline at end of file diff --git a/vnpy/trader/app/optionMaster/om.ico b/vnpy/trader/app/optionMaster/om.ico new file mode 100644 index 00000000..d8a4c0be Binary files /dev/null and b/vnpy/trader/app/optionMaster/om.ico differ diff --git a/vnpy/trader/app/optionMaster/omBase.py b/vnpy/trader/app/optionMaster/omBase.py new file mode 100644 index 00000000..c7d557ec --- /dev/null +++ b/vnpy/trader/app/optionMaster/omBase.py @@ -0,0 +1,3 @@ +# encoding: UTF-8 + +