Mqrcm-package {Mqrcm}R Documentation

M-Quantile Regression Coefficients Modeling

Description

This package implements Frumento and Salvati (2020) method for M-quantile regression coefficients modeling (Mqrcm), in which M-quantile regression coefficients are described by (flexible) parametric functions of the order of the quantile. This permits modeling the entire conditional M-quantile function of a response variable.

Details

Package: Mqrcm
Type: Package
Version: 1.3
Date: 2024-02-12
License: GPL-2

The function iMqr permits specifying the regression model. Two special functions, slp and plf, are provided to facilitate model building. The auxiliary functions summary.iMqr, predict.iMqr, and plot.iMqr can be used to extract information from the fitted model.

Author(s)

Paolo Frumento

Maintainer: Paolo Frumento <paolo.frumento@unipi.it>

References

Frumento, P., Salvati, N. (2020). Parametric modeling of M-quantile regression coefficient functions with application to small area estimation, Journal of the Royal Statistical Society, Series A, 183(1), p. 229-250.

Examples


# use simulated data

n <- 250
x <- rexp(n)
y <- runif(n, 0, 1 + x)
model <- iMqr(y ~ x, formula.p = ~ p + I(p^2))
summary(model)
summary(model, p = c(0.1,0.2,0.3))
predict(model, type = "beta", p = c(0.1,0.2,0.3))
predict(model, type = "CDF", newdata = data.frame(x = c(1,2,3), y = c(0.5,1,2)))
predict(model, type = "QF", p = c(0.1,0.2,0.3), newdata = data.frame(x = c(1,2,3)))
predict(model, type = "sim", newdata = data.frame(x = c(1,2,3)))
par(mfrow = c(1,2)); plot(model, ask = FALSE)

[Package Mqrcm version 1.3 Index]