Location-Varying Gating for Mixtures of Quantile Regressions

Extends finite mixtures of quantile regressions (the 'mixqr' package) with a concomitant-covariate, quantile-indexed mixing gate. The mixing probabilities follow a multinomial-logit model whose coefficients may depend on a separate set of gating covariates and on the quantile level, so that latent-class membership can change across the conditional distribution. This turns the location-varying mixing idea of Furno (2025) into a likelihood and EM object with proper standard errors on the gate. Estimation reuses the 'mixqr' component and error-density machinery; the gate is fit by a weighted multinomial-logistic M-step and reduces exactly to a constant gate when the gating model is an intercept only.


mixqrgate

Lifecycle: experimental License: MIT

Location-varying gating for mixtures of quantile regressions

mixqrgate extends mixqr so that the mixing probabilities of a finite mixture of quantile regressions can depend on covariates — and on the quantile level. The mixing weights follow a multinomial-logit gate; with a quantile-indexed gate, latent-class membership can change across the conditional distribution. An observation may belong to one regime near the median and another in the tail.

This is the location-varying mixing of Furno (2025), turned from a Stata reweighting heuristic into a likelihood/EM object — with standard errors on the gate, which the original method does not provide.

Installation

# install.packages("remotes")
remotes::install_github("kvenkita/mixqr")       # required
remotes::install_github("kvenkita/mixqrgate")

Quick start

library(mixqrgate)

d <- sim_gate2(n = 600, gamma = c(0, 1.5))      # gate depends on z

# concomitant gate at the median
fit <- mixqrgate(y ~ x, data = d, gating = ~ z, G = 2, tau = 0.5)
summary(fit)          # component coefficients + gate coefficients WITH SEs

# location-varying gate: refit the gate at each quantile
fitv <- mixqrgate(y ~ x, data = d, gating = ~ z, G = 2,
                  tau = c(0.1, 0.5, 0.9), vary_gating = "discrete")
plot(fitv, which = "gating")                    # gate-vs-tau picture

Key features

  • Concomitant gate. gating = ~ z1 + z2 puts a multinomial logit on the mixing probabilities; the gating covariates may differ from the component-regression covariates.
  • Quantile-indexed gate. A vector tau with vary_gating = "discrete" refits the gate at each quantile, so membership can vary across the distribution (Furno's location-varying mixing).
  • Inference on the gate. Sandwich standard errors, z- and p-values per quantile — answer whether and how membership changes with the covariates and with tau.
  • Reduces to mixqr. gating = ~1 gives a constant gate and the ordinary mixture-of-quantile-regressions fit.
  • Two engines. Parametric asymmetric-Laplace (method = "ald") or the Wu & Yao nonparametric kernel-density path (method = "kde").

Relationship to mixqr

mixqrgate reuses mixqr's component and constrained-error-density machinery through its extension API (weighted_rq(), constrained_kde()); only the gate is new. The component estimates, diagnostics, and quantile semantics are those of mixqr.

Citation

Venkitasubramanian, K. (2026). mixqrgate: Location-Varying Gating for Mixtures of Quantile Regressions. R package version 0.1.0.

Please also cite Furno (2025) for the location-varying mixing idea and Wu & Yao (2016) for the mixture-of-quantile-regressions estimator.

Author and license

Created and maintained by Kailas Venkitasubramanian, University of North Carolina at Charlotte. MIT licensed.

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("mixqrgate")

0.1.2 by Kailas Venkitasubramanian, 3 months ago


https://github.com/kvenkita/mixqrgate


Report a bug at https://github.com/kvenkita/mixqrgate/issues


Browse source code at https://github.com/cran/mixqrgate


Authors: Kailas Venkitasubramanian [aut, cre, cph]


Documentation:   PDF Manual  


MIT + file LICENSE license


Imports mixqr, stats, graphics

Suggests nnet, ggplot2, testthat, knitr, rmarkdown


See at CRAN