| .fit.quantile | R Documentation |
tidyfitFits a linear quantile regression on a 'tidyFit' R6 class. The function can be used with regress.
## S3 method for class 'quantile'
.fit(self, data = NULL)
self |
a 'tidyFit' R6 class. |
data |
a data frame, data frame extension (e.g. a tibble), or a lazy data frame (e.g. from dbplyr or dtplyr). |
Hyperparameters:
None. Cross validation not applicable.
Important method arguments (passed to m)
tau (the quantile(s) to be estimated)
The function provides a wrapper for quantreg::rq. See ?rq for more details. The argument tau is the chosen quantile (default tau = 0.5).
Implementation
No implementation notes
A fitted 'tidyFit' class model.
Johann Pfitzinger
Koenker R (2022). quantreg: Quantile Regression. R package version 5.94, https://CRAN.R-project.org/package=quantreg.
.fit.lm, .fit.bayes and m methods
# Load data
data <- tidyfit::Factor_Industry_Returns
fit <- regress(data, Return ~ .,
m("quantile", tau = c(0.1, 0.5, 0.9)),
.mask = c("Date", "Industry"))
coef(fit)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.