Find the location of the maximum of a smoothing spline
findSplineMax(x, y, n = 1000, spar = NULL)Numeric vector of x values.
Numeric vector of y values (same length as x).
Integer, number of grid points to evaluate (default 1000).
Smoothing parameter passed to stats::smooth.spline.
A named list with components:
The x coordinate at which the spline reaches its maximum.
The corresponding maximum fitted y value.