monreg: Estimating Monotone Regression Functions Nonparametrically

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/monreg.r

Description

monreg provides a strictly monotone estimator of the regression function based on the nonparametric regression model.

Usage

1
2
3
monreg(x, y, a = min(x), b = max(x), N = length(x), t = length(x),
       hd, Kd = "epanech", hr, Kr = "epanech", degree = 1,
       inverse = 0, monotonie = "isoton")

Arguments

x

vector containing the x-values (design points) of a sample

y

vector containing the y-values (response) of a sample

a

lower bound of the support of the design points density function, or smallest fixed design point

b

upper bound of the support of the design points density function, or largest fixed design point

N

number or vector of evaluation points of the unconstrained nonparametric regression estimator (e.g. Nadaraya-Watson estimator)

t

number or vector of points where the monotone estimation is computed

hd

bandwith of kernel K_d of the density estimation step

Kd

Kernel for the density estimation step (monotonization step). 'epanech' for Epanechnikov, 'rectangle' for rectangle, 'biweight' for biweight, 'triweight' for triweight, 'triangle' for triangle, 'cosine' for cosine kernel

hr

bandwith of kernel K_r of the regression estimation step.

Kr

Kernel for the regression estimation step (unconstrained estimation). 'epanech' for Epanechnikov, 'rectangle' for rectangle, 'biweight' for biweight, 'triweight' for triweight, 'triangle' for triangle, 'cosine' for cosine kernel.

degree

Determines the method for the unconstrained estimation. '0' for the classical Nadaraya-Watson estimate, '1' for the local linear estimate. As well degree can be the vector of the unconditional estimator provided by the user for the design points given in the vector N

inverse

For '0' the original regression function is estimated, for '1' the inverse of the regression function is estimated.

monotonie

Determines the type of monotonicity. 'isoton<b4> if the regression function is assumed to be isotone, 'antinton' if the regression function is assumed to be antitone.

Details

Nonparametric regression models are of the form Y_i = m(X_i) + σ(X_i) \cdot \varepsilon_i, where m is the regression funtion and σ the variance function. monreg performs a monotone estimate of the unknown regression function m. monreg first estimates m by an unconstrained nonparametric method, the classical Nadaraya-Watson estimate or the local- linear estimate (unless the user decides to pass his or her own estimate). In a second step the inverse of the (monotone) regression function is calculated, by monotonizing this unconstrained estimate. With the above notation and \hat m for the unconstrained estimate, the second step writes as follows,

\hat m_I^{-1} = \frac{1}{Nh_d} ∑\limits_{i=1}^N \int\limits_{-∞}^t K_d \Bigl( \frac{\hat m (\frac{i}{N} ) - u}{h_d} \Bigr) \; du.

Finally, the monotone estimate achieved by inversion of \hat m_I^{-1}.

Value

monreg returns a list of values

xs

the input values x, standardized on the interval [0,1]

y

input variable y

z

the points, for which the unconstrained function is estimated

t

the points, for which the monotone function values will be estimated

length.x

length of the vector x

length.z

length of the vector z

length.t

length of the vector t

hd

bandwidth used with the Kernel K_d

hr

bandwidth used with the Kernel K_r

Kd

kernel used for the monotonization step

Kr

kernel used for the initial unconstrained regression estimate

degree

method, which was used for the unconstrained regression estimate

ldeg.vektor

length of the vector degree. If ldeg.vektor is not equal to 1 the user provided the vector of the unconditional estimator for the design points given in the vector N

inverse

indicates, if the origin regression function or its inverse has been estimated

estimation

the monotone estimate at the design points t

...

Author(s)

This R Package was developed by Kay Pilz and Stefanie Titoff. Earlier developements of the estimator were made by Holger Dette and Kay Pilz.

See Also

monvardiff and monvarresid for monotone variance function estimation.

Examples

1
2
3
4
x <- rnorm(100)
y <- x + rnorm(100)
mon1 <- monreg(x, y, hd = .5, hr = .5)
plot(mon1$t, mon1$estimation)

Example output



monreg documentation built on April 26, 2020, 9:05 a.m.

Related to monreg in monreg...