The Function nearestNeigbourInterpolation is only a private function that can not be used by the user and only calls the closestValue which is public. Therefor I suggest to leave nearestNeighbourInterpolation out and directly use closestValue in the interpolation.
I think the only argument to keep it would be that it is easier to read with the seprate function.
The Function
nearestNeigbourInterpolation
is only a private function that can not be used by the user and only calls theclosestValue
which is public. Therefor I suggest to leavenearestNeighbourInterpolation
out and directly useclosestValue
in theinterpolation
. I think the only argument to keep it would be that it is easier to read with the seprate function.