* BENCHMARKING: For larger data sets, most of the time is spent in `get.lam()`.
* BUG FIX: `smooth.spline(x,y)` will only use *and* return values for
"unique" {x}:s. This means that the fitted {y}:s maybe be fewer than
the input vector. In order to control for this, we use `predict()`.
* NEW FEATURE: Now `smoother` can also be a function taking arguments
`lambda`, `xj` and `...` and return `y` of the same length
as `lambda` and `xj`.
* NEW FEATURE `principal.curve()`: Arguments `start` and `stretch`
can be NULL, which behaves the same as if they are "missing"
[which is hard to emulate with for instance `do.call()`].
* NEW FEATURE: Added `converged` and `nbrOfIterations` to return structure.
* SPEED UP/MEMORY OPTIMIZATION: Now the nxp matrix 's' is allocated only
once. Before it was built up using cbind() once per iteration.
* SPEED UP: Now the smoother function is identified/created before
starting the algorithm, and not once per dimension and iteration.
* MEMORY OPTIMISATION `principal.curve()`: Now the result matrix
allocated as doubles, not logicals (as NA is), in order to
prevent a coersion.
* BUG FIX: An error was thrown if `smoother` was a function.
* MINOR CHANGES: Cleaned up source code (removed comments).