Skip to contents

Model fitting

The main entry point and its control settings. mixqr() also hosts the expectile and M-quantile component-loss families via its family = argument.

mixqr()
Fit a finite mixture of quantile regressions
mixqr_control()
Control parameters for mixqr()
mixqr_vcontrol()
Control parameters for stochastic-EM variance estimation (Algorithm 3.1)

Model selection

mixqr_select()
Select the number of mixture components

Variable selection

Component-specific penalized selection of covariates.

mixqr_pen()
Fit a penalized (variable-selecting) mixture of quantile regressions
selectedVars()
Active (selected) covariates per component of a penalized mixqr fit

Non-crossing / multi-quantile

Joint estimation at several quantile levels with shared classification and guaranteed non-crossing.

mixqr_nc()
Fit a joint multi-tau mixture of quantile regressions (non-crossing, shared labels)
predict(<mixqr_multitau>)
Predict non-crossing component quantiles from a multi-tau fit
plot(<mixqr_multitau>)
Plot the non-crossing component quantile curves of a multi-tau fit
sim_mixqr_cross()
Simulate a two-component mixture whose per-tau fits cross (for O4 validation)

Estimates, inference, and prediction

Extract coefficients, standard errors, intervals, and predictions.

summary(<mixqr>)
Summarize a mixqr fit
coef(<mixqr>)
Component coefficients of a mixqr fit
confint(<mixqr>)
Confidence intervals for a mixqr fit
vcov(<mixqr>)
Variance-covariance matrix of a mixqr fit
predict(<mixqr>)
Predict from a mixqr fit
fitted(<mixqr>) residuals(<mixqr>) nobs(<mixqr>)
Fitted values, residuals and number of observations
logLik(<mixqr>) AIC(<mixqr>) BIC(<mixqr>)
Log-likelihood, AIC and BIC of a mixqr fit
plot(<mixqr>)
Plot a mixqr fit

Simulation and data

Reproducible designs and the bundled example dataset.

sim_mixqr2()
Simulate the Wu & Yao two-component design (eq. 4.1-4.2)
sim_mixqr3()
Simulate the Wu & Yao three-component design (eq. 4.3-4.4)
engine
Engine ethanol-combustion data (Brinkman 1981)

Extending mixqr

The engine contract and reusable building blocks for custom EM engines and companion packages (QMM sub-projects 03-06).

register_mixqr_engine()
Register a mixqr EM engine
get_mixqr_engine()
Retrieve a registered mixqr engine constructor
list_mixqr_engines()
List registered mixqr engines
weighted_rq()
Weighted quantile regression for one mixture component
constrained_kde()
Constrained KDE update for all components (eq. 2.5 unequal / eq. 2.8 equal).

Package

mixqr-package
mixqr: An Extensible Framework for Mixtures of Quantile and Expectile Regressions