For those using PyCharm, you may encounter a "type NoneType doesn't define __round__ method" error message. You just need to add a "return price" clause before the elif. And it works. Thanks ASX!
thank you for this instructive video..I however have a question: why do several practitioners add a shift parameter when pricing with negative rates for example in a case of a caplet or a floorlet and they call it the shifted black model?
Hi, I have encountered this error in PyCharm: print("Option price is: ", round(blackscholes(r ,S ,K, T, sigma, type="C"), 2) ) TypeError: type NoneType doesn't define __round__ method. How can I resolve?
I get this Error: Black_Scholes.py:17: RuntimeWarning: divide by zero encountered in log d1 = (np.log(S/K)+(r+sigma**2/2)*T)/(sigma*np.sqrt(T)) ('Option price is: ', 0.0) Can someone help me? (Using VSCode on m1 mac)
The Black and Scholes equation is wrong: The Black and Scholes (risk-neutral) premium is the first moment of the option expiry for an asset that has all risk and no market return (the risk-neutral measure), that which has been debased of market return (by holding portfolio returns fixed flat at r). This idiotic asset (the risk-neutral measure) is stochastically dominated by bonds in that bonds have the same return (r) but without the risk whilst it is stochastically dominated by stocks since stocks earn market return for the equivalent amount of risk: bonds have LOWER RISK for the SAME RETURN as the debased market asset (the risk-neutral measure) whilst stocks have HIGHER RETURN for the SAME RISK as the debased market asset (the risk-neutral measure) Either way, the 'risk-neutral measure' is totally idiotic and stochastically dominated by all non-redundant asset classes. It is not deep and it is not abstract. All it is is the market asset without return (which is then used to price the derivative and so is wrong and inaccurate). If a trader wants an option, then he must not take an offsetting position that nullifies the option position. There is nothing risk-neutral about that. An option premium must have a mean mu in the drift term, otherwise it is wrong... wrong for derivatives and wrong for efficient and non-communist finance. nb: I had to say 'no risk' when I sat several of the courses in undergraduate (almost two decades ago). It was clear as day to me then that it was inaccurate (and proved by me definitively now more than one decade ago).