Answered step by step
Verified Expert Solution
Question
1 Approved Answer
2) This exercise concerns the Black-Scholes formula for the price of a European vanilla option and the calculation of the implied volatility. All code should
2) This exercise concerns the Black-Scholes formula for the price of a European vanilla option and the calculation of the implied volatility. All code should be in R. A) Create a BSOptionPrice function that takes the variables as input: - S : the current price of the risky asset (St), - K : the exercise price of the option (K), - r : the risk-free rate (r), - T_t: the time in years until the option expires (Tt), - sigma: the volatility of the risky asset (), - isput: a Boolean variable such as TRUE indicates a put option and FALSE a call option, and which gives as output the price of a European vanilla option under the BlackScholes model (either a call option or a put option). B) Evaluate your function for a call option and a put option with the following parameters: S0=100,K=105,r=2%,T=0.5,=20%. C) Create a BSImplicitVol function which takes as input the variables OptionPrice: the current price of the option, - S : the current price of the risky asset (St), - K : the exercise price of the option (K), - r : the risk-free rate (r), - T_t: the time in years until the option expires (Tt), - isput: a Boolean variable such as TRUE indicates a put option and FALSE a call option, and which gives as output the value of the implicit volatility of the option considered. Of course, it is not allowed to use a pre-programmed function for implicit volatility in an R library. Suggestion: Your function could call the uniroot function in R. D) Use your function to calculate the implied volatility of a call option with a price of 2.7852 under the assumptions: S0=100,K=105,r=2%,T=0.25. E) Use your function to calculate the implied volatility of a put option with a price of 6.8249 under the assumptions: S0=100,K=105,r=2%,T=0.75
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started