@@ -813,10 +813,10 @@ def _linear_interpolation(x0, y0, x1, youtleft, youtright):
813813 y1 [m1 ] = w0lo * y0 [ilo0 ] + w0hi * y0 [ihi0 ]
814814 return y1
815815
816+
816817def grid_interpolation (x0 , y0 , x1 , tp , left = None , right = None ):
817- """
818- Interpolate values from one grid onto another using either linear
819- or Whittaker–Shannon interpolation.
818+ """Interpolate values from one grid onto another using either linear or
819+ Whittaker–Shannon interpolation.
820820
821821 Parameters
822822 ----------
@@ -827,11 +827,11 @@ def grid_interpolation(x0, y0, x1, tp, left=None, right=None):
827827 x1 : array_like
828828 New x-grid upon which to interpolate.
829829 tp : {'data', 'Nyquist', 'custom'}, optional
830- Corresponding fit sampling type. Use Whittaker–Shannon interpolation
830+ Corresponding fit sampling type. Use Whittaker–Shannon interpolation
831831 for Nyquist resampling and linear interpolation otherwise.
832832 If not provided, linear interpolation is used.
833833 left : float, optional
834- Value for interpolated y1 for x1 below the x0 range.
834+ Value for interpolated y1 for x1 below the x0 range.
835835 Default: if tp='Nyquist' then y1[0] is used. Otherwise 0.0 is used.
836836 right : float, optional
837837 Value for interpolated y1 for x1 above the x0 range.
@@ -847,7 +847,7 @@ def grid_interpolation(x0, y0, x1, tp, left=None, right=None):
847847 When tp='Nyquist', the function calls :func:`wsinterp` to perform Whittaker–Shannon interpolation.
848848 Otherwise it uses the internal :func:`_linear_interpolation` routine.
849849 """
850- if tp == ' Nyquist' :
850+ if tp == " Nyquist" :
851851 return wsinterp (x1 , x0 , y0 , left , right )
852852 else :
853853 left = 0.0 if left is None else left
0 commit comments