@@ -614,11 +614,11 @@ def _updateRcalcSampling(self):
614
614
tp = self .getFitSamplingType ()
615
615
# Gcalc:
616
616
if len (self ._Gcalc ) > 0 :
617
- newGcalc = grid_interpolation (self ._rcalc , self ._Gcalc , newrcalc , tp )
617
+ newGcalc = grid_interpolation (self ._rcalc , self ._Gcalc , newrcalc , tp = tp )
618
618
self ._Gcalc = list (newGcalc )
619
619
# dGcalc
620
620
if len (self ._dGcalc ) > 0 :
621
- newdGcalc = grid_interpolation (self ._rcalc , self ._dGcalc , newrcalc , tp )
621
+ newdGcalc = grid_interpolation (self ._rcalc , self ._dGcalc , newrcalc , tp = tp )
622
622
self ._dGcalc = list (newdGcalc )
623
623
# invalidate Gtrunc and dGtrunc
624
624
self ._Gtrunc = []
@@ -712,7 +712,7 @@ def _get_Gtrunc(self):
712
712
self ._updateRcalcSampling ()
713
713
if not self ._Gtrunc :
714
714
tp = self .getFitSamplingType ()
715
- newGtrunc = grid_interpolation (self .robs , self .Gobs , self .rcalc , tp )
715
+ newGtrunc = grid_interpolation (self .robs , self .Gobs , self .rcalc , tp = tp )
716
716
self ._Gtrunc = list (newGtrunc )
717
717
return self ._Gtrunc
718
718
@@ -733,9 +733,9 @@ def _get_dGtrunc(self):
733
733
self .robs ,
734
734
self .dGobs ,
735
735
self .rcalc ,
736
- tp ,
737
736
left = sum (self .dGobs [:1 ]),
738
737
right = sum (self .dGobs [- 1 :]),
738
+ tp = tp ,
739
739
)
740
740
self ._dGtrunc = list (newdGtrunc )
741
741
return self ._dGtrunc
@@ -814,7 +814,7 @@ def _linear_interpolation(x0, y0, x1, youtleft, youtright):
814
814
return y1
815
815
816
816
817
- def grid_interpolation (x0 , y0 , x1 , tp , left = None , right = None ):
817
+ def grid_interpolation (x0 , y0 , x1 , left = None , right = None , tp = None ):
818
818
"""Interpolate values from one grid onto another using either linear or
819
819
Whittaker–Shannon interpolation.
820
820
0 commit comments