.quantilePercentiles {JWileymisc} | R Documentation |
Internal Function to Calculate Quantiles
Description
Function calculates smoothing spline quantiles or linear quantiles as a fall back. Not intended for general use. Expected predicted and residual data. Exported to support related packages.
Usage
.quantilePercentiles(data, LL = 0.1, UL = 0.9, na.rm = TRUE, cut = 4L)
Arguments
data |
A dataset of predicted and residual values. Assumed from some sort of (probably parametric) model. |
LL |
The lower limit for prediction. Defaults to
|
UL |
The upper limit for prediction. Defaults to
|
na.rm |
A logical whether to remove missing values.
Defaults to |
cut |
An integer, how many unique predicted values there have to be at least for it to use quantile regression or treat the predicted values as discrete. Defaults to 4. |
Value
A data.table with the scores and predicted LL and UL, possibly missing if quantile regression models do not converge.