# HG changeset patch # User Kris Thielemans # Date 1221977667 -7200 # Node ID c6c678875825fd2c7e8c566be069d8bda9a3196f # Parent 28b0618cf67c64eb8195755c25ed28fdc269f65c For for extrapval in interpn diff --git a/doc/interpreter/contributors.in b/doc/interpreter/contributors.in --- a/doc/interpreter/contributors.in +++ b/doc/interpreter/contributors.in @@ -188,6 +188,7 @@ Ariel Tankus Georg Thimm Duncan Temple Lang +Kris Thielemans Olaf Till Thomas Treichl Utkarsh Upadhyay diff --git a/scripts/ChangeLog b/scripts/ChangeLog --- a/scripts/ChangeLog +++ b/scripts/ChangeLog @@ -1,3 +1,8 @@ +2008-09-18 Kris Thielemans + + * general/interpn.m: Fixe for extrapval and documentation of + extrapval. + 2008-09-19 David Bateman * general/cell2mat.m: Specialize 2D case for speed. diff --git a/scripts/general/interpn.m b/scripts/general/interpn.m --- a/scripts/general/interpn.m +++ b/scripts/general/interpn.m @@ -55,9 +55,9 @@ ## ## The default method is 'linear'. ## -## If @var{extrap} is the string 'extrap', then extrapolate values beyond -## the endpoints. If @var{extrap} is a number, replace values beyond the -## endpoints with that number. If @var{extrap} is missing, assume NA. +## If @var{extrapval} is the scalar value, use it to replace the values +## beyond the endpoints with that number. If @var{extrapval} is missing, +## assume NA. ## @seealso{interp1, interp2, spline, ndgrid} ## @end deftypefn @@ -79,6 +79,7 @@ error ("extrapal is expected to be a numeric scalar"); endif method = varargin{end - 1}; + extrapval = varargin{end}; nargs = nargs - 2; endif