Diff of /inst/blsimpv.m [c08269] .. [9492cd] Maximize Restore

  Switch to side-by-side view

--- a/inst/blsimpv.m
+++ b/inst/blsimpv.m
@@ -100,7 +100,7 @@
 
       ## Construct function
       if (Class(j, k)) # call
-        fun = @(x) blsprice (Price(j, k), Strike(j, k), Rate(j, k), Time(j, k), x,
+        fun = @(x) blscall (Price(j, k), Strike(j, k), Rate(j, k), Time(j, k), x,
                              Yield(j, k)) - Value(j, k);
       else # put
         fun = @(x) blsput (Price(j, k), Strike(j, k), Rate(j, k), Time(j, k), x,
@@ -133,12 +133,12 @@
 endfunction
 
 function [C, v] = blscall (Price, Strike, Rate, Time, x, Yield)
-  [C, P]  = blsprice (Price, Strike, Rate, Time, x, Yield);
-  v       = blsvega  (Price, Strike, Rate, Time, x, Yield);
+  C = blsprice (Price, Strike, Rate, Time, x, Yield);
+  v = blsvega  (Price, Strike, Rate, Time, x, Yield);
 endfunction
 
 function [P, v] = blsput (Price, Strike, Rate, Time, x, Yield)
-  [C, P]  = blsprice (Price, Strike, Rate, Time, x, Yield);
+  [~, P]  = blsprice (Price, Strike, Rate, Time, x, Yield);
   v       = blsvega  (Price, Strike, Rate, Time, x, Yield);
 endfunction