knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>",
  fig.path = "man/figures/README-",
  out.width = "100%"
)

REGRM

The goal of REGRM is to provide convenient tools for robust estimation of a generalized ratio model, $y_i=\beta x_i + x_i^\gamma \varepsilon_i$, where $\varepsilon$ is a homoscedastic error term.

The conventional ratio model $y_i = \beta x_i + \epsilon_i$ has the heteroscedastic error term $\epsilon$ and this is the obstacle to have robust estimation by means fo M-estimator.

The ratio model is re-defined with homoscedastic error term $\varepsilon$, generalized with the power $\gamma$ to $\varepsilon$, and robustified by means of M-estimation. The algorithm used is the iteratively re-weighted least squares (IRLS).

The corresponding estimator is shown as follows:

$$ \hat{\beta}{rob}=\frac{\sum^n{i=1}w_i y_i x_i^{1-2\gamma}}{\sum^n_{i=1} w_i x_i^{2(1-\gamma)}}, $$ where $w_i$ is obtained by a weight function. The conventional ratio model is obtained when $\gamma=1/2$.

Two different weight functions, two different scale prameters, and three choices of the gamma value can be used. There are 12 functions according to these settings.

Functions included

An integrated function REGRM calls an appropriate child function shown in the table internally. REGRM only accepts the tuning parameter c2=4, 6 or 8 and the value will be automatically converted according to the internal 12 founctions.

|Weight function|$\gamma=1$|$\gamma=1/2$|$\gamma=0$| |----|----|----|----| |Tukey's biweight function & AAD scale|RrTa.aad|RrTb.aad|RrTc.aad| |Tukey's biweight function & MAD scale|RrTa.mad|RrTb.mad|RrTc.mad| |Huber's weight function & AAD scale|RrHa.aad|RrTb.aad|RrTc.aad| |Hukey's weight function & MAD scale|RrHa.mad|RrHb.mad|RrHc.mad|

If a user wish to select other values of the tuning parameter, any child functions can be called directly. In this case, the tuning parameter c1 should be selected appropriately according to the list below.

|function|Very robust|...|Less robust|Default| |----|----|----|----|----| |REGRM|4|6|8|8| |Tukey AAD|4|6|8|8| |Tukey MAD(SD) |5.01|7.52|10.03|10.03| |Huber AAD|1.15|1.72|2.30|2.30| |Huber MAD(SD)|1.44|2.16|2.88|2.88|

Installation

You can install the development version from GitHub with:

``` {r eval=FALSE}

install.packages("devtools")

devtools::install_github("kazwd2008/REGRM") ```



kazwd2008/REGRM documentation built on Nov. 20, 2019, 9:46 a.m.