FIN285a: Problem Set 9 (last problem set)

Fall 2011

Due Wednesday, November 30th
  1. You are interested in evaluating the VaR of two fixed coupon bonds. One bond has a 1 year maturity and pays a coupon in 6 months, and a coupon and principal of 1000 in 12 months. The other bond has the same coupon and principal, but is a 2 year bond again paying interest twice a year. The coupons are fixed at 2.5% of the principal. Both bonds are currently valued at a 5% (per year) interest rate. The monthly percentage change in the interest rate, x, is assumed to be normally distributed with a mean of zero, and a std of 0.01. For example, next month's rate would then be r = 0.05(1+x). For all VaR calculations below perform a 100,000 monte-carlo. Assume a flat term structure for all parts of this problem, and semi annual compounding. This would give a sequence of discount rates of (1+r/2), (1+r/2)^2, (1+r/2)^3, r = the interest rate in annual units.
    1. Find the 6 month, 1 percent VaR for both these bonds. Use the discounting with semi-annual periods as your basis as we did for the floating swap in class.
    2. Now find the 6 month VaR for the one year bond, but replace the coupon with a floating rate interest payment which equals (1/2)r*1000 where r is the interest rate 6 months prior to the payment date. Find the 6 month, 1 percent VaR for this security. The floating rate coupon in this problem is something new, but it is common in the world of bonds, and lends itself to computer simulation. For this 12 month bond the first coupon (in 6 months) would be known today since it is based on today's interest rate. The coupon in 12 months will not be known until 6 months in the future when it is determined by r(6)*F with r(6) = the interest rate in 6 months. Armed with these hints this problem should be doable.
      % Estimate VaR for simple bond portfolio 
      
      rtoday = 0.05
      niterat = 10000;
      
      % bond parameters
      princ = 1000;
      coupon = 0.5*0.05;
      mu = 0;
      sigma = 0.01;
      % var confidence level
      varcl = 0.99;
      
      % current bond price (annual coupon, starting in 1 year)
      bprice = coupon*princ/(1+0.5*rtoday) + coupon*princ/(1+0.5*rtoday)^2;
      
      % future bond price vector
      bfprice = zeros(1000,1);
      
      % simulate 12 month yield moves
      for iterat = 1:niterat
          dtbsim = normal(12,mu,sigma^2); 
          % yield in 12 months time
          r6 = rtoday*(prod(1+dtbsim(1:6)));
          r12 = rtoday*(prod(1+dtbsim))
          % bond price 6 months from now
          bfprice(iterat) = coupon*princ + (princ+coupon*princ)/(1+0.5*r6);
      end
      
      % var critical price
      pcritical = quantile(bfprice,1-varcl)
      % var : discounted at t-bill rate
      var = (bprice - pcritical)/(1+0.5*rtoday)
      
      % now do floating
      % simulate 12 month yield moves
      for iterat = 1:niterat
          dtbsim = normal(12,mu,sigma^2); 
          % yield in 12 months time
          r6 = rtoday*(prod(1+dtbsim(1:6)));
          r12 = rtoday*(prod(1+dtbsim))
          % set floating coupon using 6 month ahead interest rate
          fcoupon = 0.5*r6;
          bfprice(iterat) = coupon*princ + (princ+fcoupon*princ)/(1+0.5*r6);
      end
      
      % var critical price
      pcritical = quantile(bfprice,1-varcl)
      % var : discounted at t-bill rate
      var = (bprice - pcritical)/(1+0.5*rtoday)
      
      
  2. Start with our simple option pricing program for the dow, putdow. Write a program to calculate three values for 11 different portfolios. These portfolios cover fractions of the position with the put option. Let the fractions vary from 0 to 1 by 0.1. (Use a for loop to do this.) Use the bootstrap (10,000 iterations) to estimate 3 different values for each different option position. Find the total cost of the option on the current day, the expected return on the entire portfolio, and the 1 percent confidence VaR.
    % find VaR for portfolio with at the money put 
    % option is European put struck at the the current price
    %   Expiration is in 1 day
    
    % The problem asks for a bootstrap which is not really clear
    %   This would probably be better done with a historical VaR as in this example here
    
    % load daily dow
    load ../data/dow.dat
    
    j = 1; % start counter
    for hedgefrac = [0:0.1:1]
    
    % parameters
    shares = 100;
    options = hedgefrac*shares;
    startprice = 1;
    strike = startprice; % at the money
    
    % extract price series
    p = dow(:,2);
    
    % 1 day arithmetic return
    ret1 = (p(2:end)-p(1:end-1))./p(1:end-1);
    % 1 day geometric return
    ret1g = log ( p(2:end)./p(1:end-1) );
    s = std(ret1g);
    syear = sqrt(250)*s;
    % portfolio value today: black/scholes option value
    [coption, poption, delta] = callput(startprice,strike,syear,0.03,1/250);
    portvtoday = shares*startprice + options*poption;
    portvtoday
    poption
    % vector of values 1 day from now
    port1day = shares*startprice*(ret1+1) + ...
        options*max( strike - startprice*(1+ret1),0);
    % find historical var using direct percentile on portfolio values
    %    report the oposite of the loss 
    
    var95(j) = portvtoday - quantile(port1day,0.05)
    pret(j) = (mean(port1day)-portvtoday)/portvtoday;
    optcost(j) = options*poption;
    
    j = j+1; % increment counter
    end
    
    
  3. For this problem use the software from class on the barrier option, barrieropt.m. Set the barrier price to 95.
    1. Rerun the program. Compare VaR in the unhedged and barrier hedged portfolios. Which is larger?
      You results may differ a little from mine, but the basic parts should be close. For me I got VaR(unhedged) = 7.46, and VaR(barrier)=7.97. This does seem strange.
    2. This seems strange. Could this be caused by the price of the option? Rerun the program, setting the price to zero, and see if the result persists.
      In this case I get VaR(barrier) = VaR(unhedged) = 7.4055. Exactly the same.
    3. What is the critical value for the porfolio (ie. quantile(futureval,0.05))? How is this impacted by the option position?
      In both cases I get 92.59. No difference between the barrier and unhedged quantiles.
    4. Why do we get this strange result that VaR increases? Why might investors still want to purchase an option which impacts the portfolio in this way?
      What is happening is that the barrier is so high, that the option is deactivating for the kind of tail risks we are interested in (0.05 quantiles). It is providing no protection for this level of VaR. The option portfolio looks riskier since it has to deal with the cost of the option too, and that becomes another part of the risk since it is in the current value of the portfolio. You have essentially purchased insurance which is useless for the VaR level you want to cover.