summary.qrmix: Summarizing qrmix Fits

Description Usage Arguments Value Examples

View source: R/summaryqrmix.R

Description

summary method for class "qrmix"

Usage

1
2
## S3 method for class 'qrmix'
summary(object, fitMethod=NULL, data=NULL, ...)

Arguments

object

an object of class "qrmix".

fitMethod

an optional refitting method if the user wants a method different than the one used to obtain "object" Use "lm" for OLS, "rlm" for robust regression, and "rq" to use fit from quantile regression.

data

data used to fit object if it is not contained in object.

...

other argumets passed to other methods.

Value

residuals

the residuals, response minus fitted values.

clusters

cluster assignment for each observation.

call

the matched call.

fitMethod

the fitting method used to obtain residuals and clusters.

quantiles

the set of k quantiles that minimize the mean loss.

clusters#

generic summary from function fitMethod for data in cluster #.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
data(blood.pressure)

#qrmix model using default function values:
mod1 = qrmix(bmi ~ ., data = blood.pressure, k = 3)

#summary using fitMethod = "rlm" instead of the one used when fitting the model mod1
summary1 = summary(mod1, fitMethod = "rlm")

#Are the quantiles selected in this case the same as in the original model?
summary1$quantiles
mod1$quantiles

qrmix documentation built on May 2, 2019, 11:04 a.m.

Related to summary.qrmix in qrmix...